[glib: 6/8] Fix signedness warning in gio/gdummyfile.c
- From: Philip Withnall <pwithnall src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib: 6/8] Fix signedness warning in gio/gdummyfile.c
- Date: Tue, 16 Feb 2021 13:11:43 +0000 (UTC)
commit e939550cad84e61af0da5775fb5ce062ceb6433e
Author: Emmanuel Fleury <emmanuel fleury gmail com>
Date: Wed Nov 18 19:33:51 2020 +0100
Fix signedness warning in gio/gdummyfile.c
gio/gdummyfile.c: In function ‘unescape_string’:
gio/gdummyfile.c:485:32: error: comparison of integer expressions of different signedness: ‘long int’ and
‘size_t’ {aka ‘long unsigned int’}
485 | g_warn_if_fail (out - result <= strlen (escaped_string));
| ^~
gio/gdummyfile.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gio/gdummyfile.c b/gio/gdummyfile.c
index cd4acd021..58442ccbc 100644
--- a/gio/gdummyfile.c
+++ b/gio/gdummyfile.c
@@ -482,7 +482,7 @@ unescape_string (const gchar *escaped_string,
}
*out = '\0';
- g_warn_if_fail (out - result <= strlen (escaped_string));
+ g_warn_if_fail ((gsize) (out - result) <= strlen (escaped_string));
return result;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]