[mutter] input-mapper: Use g_auto to free a string array



commit 54fdd633feafc1d2c174684838c0fa62d29b51c7
Author: Marco Trevisan (Treviño) <mail 3v1n0 net>
Date:   Mon Feb 11 15:10:37 2019 +0100

    input-mapper: Use g_auto to free a string array
    
    https://gitlab.gnome.org/GNOME/mutter/merge_requests/435

 src/backends/meta-input-mapper.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
---
diff --git a/src/backends/meta-input-mapper.c b/src/backends/meta-input-mapper.c
index 2be6cc65b..31212e078 100644
--- a/src/backends/meta-input-mapper.c
+++ b/src/backends/meta-input-mapper.c
@@ -250,7 +250,7 @@ match_edid (MetaMapperInputInfo  *input,
   else
     {
       int i;
-      char **split;
+      g_auto (GStrv) split = NULL;
 
       split = g_strsplit (meta_monitor_get_product (monitor), " ", -1);
 
@@ -262,8 +262,6 @@ match_edid (MetaMapperInputInfo  *input,
               break;
             }
         }
-
-      g_strfreev (split);
     }
 
   return TRUE;


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