diff options
author | Emmanuel Fleury <emmanuel.fleury@u-bordeaux.fr> | 2020-08-27 14:26:20 +0200 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2020-08-27 19:32:11 +0300 |
commit | 856265fe669be15cfd156b720cc6614c4ae4f7a5 (patch) | |
tree | aee1f3985cf85c2c4129f44d6c80244bdb1343dc /glib/gfileutils.c | |
parent | 9674d14175374f02877dc27b1475ec5746413842 (diff) | |
download | glib-856265fe669be15cfd156b720cc6614c4ae4f7a5.tar.gz |
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)
Diffstat (limited to 'glib/gfileutils.c')
-rw-r--r-- | glib/gfileutils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/glib/gfileutils.c b/glib/gfileutils.c index 2993eacc3..8992203d6 100644 --- a/glib/gfileutils.c +++ b/glib/gfileutils.c @@ -1173,7 +1173,7 @@ write_to_file (const gchar *contents, return FALSE; } - g_assert (s <= length); + g_assert ((gsize) s <= length); contents += s; length -= s; |