diff options
author | dequis <dx@dxzone.com.ar> | 2015-01-16 16:50:23 -0300 |
---|---|---|
committer | dequis <dx@dxzone.com.ar> | 2015-01-16 16:50:23 -0300 |
commit | 6b13103dad92d505e038c268af66aeb04b7b4d87 (patch) | |
tree | 42ea01f5040065df60917daca6605318ec4f28df /irc_util.c | |
parent | 6f10697380c620065731a5beece95c0f5bd652a0 (diff) |
Replace isdigit/isalpha/.../tolower/toupper with glib variants
This fixes warnings about passing signed chars to them (apparently they
are implemented as macros that do array lookups without checks in some
platforms, yay)
Specifically:
functions=isalnum|isalpha|isdigit|isspace|isxdigit|tolower|toupper
sed -ir "s/$functions/g_ascii_&/g" **/*.c
Diffstat (limited to 'irc_util.c')
-rw-r--r-- | irc_util.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -41,9 +41,9 @@ char *set_eval_timezone( set_t *set, char *value ) s ++; /* \d+ */ - if( !isdigit( *s ) ) + if( !g_ascii_isdigit( *s ) ) return SET_INVALID; - while( *s && isdigit( *s ) ) s ++; + while( *s && g_ascii_isdigit( *s ) ) s ++; /* EOS? */ if( *s == '\0' ) @@ -55,9 +55,9 @@ char *set_eval_timezone( set_t *set, char *value ) s ++; /* \d+ */ - if( !isdigit( *s ) ) + if( !g_ascii_isdigit( *s ) ) return SET_INVALID; - while( *s && isdigit( *s ) ) s ++; + while( *s && g_ascii_isdigit( *s ) ) s ++; /* EOS */ return *s == '\0' ? value : SET_INVALID; |