Commit f567b195 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Handle errors without crashing

parent 92a4720a
......@@ -63,6 +63,8 @@ char *unescape_URI_duplicate( const char *psz )
void unescape_URI( char *psz )
{
unsigned char *in = (unsigned char *)psz, *out = in, c;
if( psz == NULL )
return;
while( ( c = *in++ ) != '\0' )
{
......@@ -144,6 +146,8 @@ char *decode_URI_duplicate( const char *psz )
void decode_URI( char *psz )
{
unsigned char *in = (unsigned char *)psz, *out = in, c;
if( psz == NULL )
return;
while( ( c = *in++ ) != '\0' )
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment