mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-27 07:56:14 +01:00
Fixing signedness warning in glib/gfileutils.c
glib/gfileutils.c: In function ‘write_to_file’: glib/gfileutils.c:1176:19: error: comparison of integer expressions of different signedness: ‘gssize’ {aka ‘long int’} and ‘gsize’ {aka ‘long unsigned int’} [-Werror=sign-compare] 1176 | g_assert (s <= length); | ^~ glib/gmacros.h:939:25: note: in definition of macro ‘G_LIKELY’ 939 | #define G_LIKELY(expr) (expr) | ^~~~ glib/gfileutils.c:1176:7: note: in expansion of macro ‘g_assert’ 1176 | g_assert (s <= length); | ^~~~~~~~ Related to issue #1735 (Get back to a -werror build)
This commit is contained in:
parent
9674d14175
commit
856265fe66
@ -1173,7 +1173,7 @@ write_to_file (const gchar *contents,
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
g_assert (s <= length);
|
g_assert ((gsize) s <= length);
|
||||||
|
|
||||||
contents += s;
|
contents += s;
|
||||||
length -= s;
|
length -= s;
|
||||||
|
Loading…
Reference in New Issue
Block a user