aboutsummaryrefslogtreecommitdiffstats
path: root/util.c
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2006-01-14 21:34:10 +0100
committerWilmer van der Gaast <wilmer@gaast.net>2006-01-14 21:34:10 +0100
commit9d6b229674144d2a48348aeb120604164f371904 (patch)
tree1af39b40c8ecab8fff7b909452d3303ef6d472c0 /util.c
parent5c577bd5e2ee33dbe7389df6f4baf659c34de365 (diff)
parent277674c82d3dbcb355214cbaceb34599832e1261 (diff)
Imported changes from main tree.
Diffstat (limited to 'util.c')
-rw-r--r--util.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/util.c b/util.c
index e4b58090..db783fe0 100644
--- a/util.c
+++ b/util.c
@@ -35,6 +35,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <ctype.h>
#include <glib.h>
#include <time.h>
@@ -376,7 +377,8 @@ void http_encode( char *s )
for( i = j = 0; t[i]; i ++, j ++ )
{
- if( t[i] <= ' ' || ((unsigned char *)t)[i] >= 128 || t[i] == '%' )
+ /* if( t[i] <= ' ' || ((unsigned char *)t)[i] >= 128 || t[i] == '%' ) */
+ if( !isalnum( t[i] ) )
{
sprintf( s + j, "%%%02X", ((unsigned char*)t)[i] );
j += 2;