]> jfr.im git - solanum.git/commitdiff
Ensure consistent indexing into user_modes independent on signedness of char.
authorJilles Tjoelker <redacted>
Wed, 14 Aug 2013 21:49:22 +0000 (23:49 +0200)
committerJilles Tjoelker <redacted>
Wed, 14 Aug 2013 21:49:59 +0000 (23:49 +0200)
src/supported.c

index 24c1e3ed5fb84882baa69eec92aadc5282c3857e..8133d548c598a8304143ff128d6ed83aeb01cceb 100644 (file)
@@ -230,7 +230,8 @@ isupport_umode(const void *ptr)
        const char *str;
 
        str = ptr;
-       return ConfigFileEntry.oper_only_umodes & user_modes[*str] ? NULL : str;
+       return ConfigFileEntry.oper_only_umodes &
+               user_modes[(unsigned char)*str] ? NULL : str;
 }
 
 static const char *