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