[glib: 1/11] Fix signedness warning in gio/gdesktopappinfo.c:get_list_of_mimetypes()




commit 46772fe4c3a7342180586d5025eab69828a1c5ab
Author: Emmanuel Fleury <emmanuel fleury gmail com>
Date:   Tue Nov 17 11:03:25 2020 +0100

    Fix signedness warning in gio/gdesktopappinfo.c:get_list_of_mimetypes()
    
    gio/gdesktopappinfo.c: In function ‘get_list_of_mimetypes’:
    gio/gdesktopappinfo.c:4116:21: error: comparison of integer expressions of different signedness: ‘gint’ 
{aka ‘int’} and ‘guint’ {aka ‘unsigned int’}
     4116 |       for (i = 0; i < array->len; i++)
          |                     ^

 gio/gdesktopappinfo.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gio/gdesktopappinfo.c b/gio/gdesktopappinfo.c
index 26e51415a..a0e8cb13d 100644
--- a/gio/gdesktopappinfo.c
+++ b/gio/gdesktopappinfo.c
@@ -4143,7 +4143,7 @@ get_list_of_mimetypes (const gchar *content_type,
 
   if (include_fallback)
     {
-      gint i;
+      guint i;
 
       /* Iterate the array as we grow it, until we have nothing more to add */
       for (i = 0; i < array->len; i++)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]