Avoid 'comparison always true...'
authorGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Fri, 18 Feb 2011 09:28:50 +0000 (04:28 -0500)
committerGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Fri, 18 Feb 2011 09:28:50 +0000 (04:28 -0500)
eglib/src/gutf8.c

index 65ffbcd7fa4c13ee345ebc4e39954f4b39eedc91..fed6dd753ca6921ff34a30fa99b43c67906853e1 100644 (file)
@@ -71,7 +71,7 @@ utf8_to_utf16_len (const gchar *str, glong len, glong *items_read, GError **erro
        ret = 0;
 
        /* Common case */
-       for (in_pos = 0; in_pos < len && str [in_pos] < 0x80; in_pos++)
+       for (in_pos = 0; in_pos < len && (guchar) str [in_pos] < 0x80; in_pos++)
                ret ++;
 
        if (in_pos == len) {