Mercurial > urweb
diff src/c/urweb.c @ 1087:e81434513720
Proper JavaScript-side URI escaping/de-escaping; fix C-side URL encoding of big characters
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Thu, 24 Dec 2009 10:44:53 -0500 |
parents | 8e240c007442 |
children | f1647f16097d |
line wrap: on
line diff
--- a/src/c/urweb.c Thu Dec 24 10:02:48 2009 -0500 +++ b/src/c/urweb.c Thu Dec 24 10:44:53 2009 -0500 @@ -1590,7 +1590,7 @@ *p++ = '_'; for (; *s; s++) { - char c = *s; + unsigned char c = *s; if (c == ' ') *p++ = '+'; @@ -1667,7 +1667,7 @@ uw_writec_unsafe(ctx, '_'); for (; *s; s++) { - char c = *s; + unsigned char c = *s; if (c == ' ') uw_writec_unsafe(ctx, '+'); @@ -1737,7 +1737,7 @@ } for (s1 = r; *s2; ++s1, ++s2) { - char c = *s2; + unsigned char c = *s2; switch (c) { case '+':