mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-25 15:06:14 +01:00
Fix signedness warning in gio/gdbusdaemon.c:is_key()
gio/gdbusdaemon.c: In function ‘is_key’: gio/gdbusdaemon.c:213:11: error: comparison of integer expressions of different signedness: ‘gsize’ {aka ‘long unsigned int’} and ‘long int’ 213 | if (len != key_end - key_start) | ^~
This commit is contained in:
parent
73499dcb73
commit
6d08c2f5ba
@ -210,7 +210,8 @@ is_key (const char *key_start, const char *key_end, const char *value)
|
||||
{
|
||||
gsize len = strlen (value);
|
||||
|
||||
if (len != key_end - key_start)
|
||||
g_assert (key_end >= key_start);
|
||||
if (len != (gsize) (key_end - key_start))
|
||||
return FALSE;
|
||||
|
||||
return strncmp (key_start, value, len) == 0;
|
||||
|
Loading…
Reference in New Issue
Block a user