summaryrefslogtreecommitdiff
path: root/tools.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tools.cpp')
-rw-r--r--tools.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools.cpp b/tools.cpp
index f6f5f5b..2d38992 100644
--- a/tools.cpp
+++ b/tools.cpp
@@ -216,7 +216,7 @@ struct urlencoder
if ( ch == ' ' )
ostr_ << '+';
- else if ( allowedChars[ size_t( ch ) ] == '_' )
+ else if ( static_cast< signed char >( ch ) < 0 || allowedChars[ size_t( ch ) ] == '_' )
ostr_ << '%' << setw( 2 ) << setfill( '0' ) << hex << int( ch );
else
ostr_ << ch;