[glib: 3/5] gsettings: Fix a minor memory leak when getting GSettingsAction:state




commit 1cde07b9789ff3b58be4af4596065d4f6fc365f0
Author: Philip Withnall <pwithnall endlessos org>
Date:   Tue Dec 15 10:54:41 2020 +0000

    gsettings: Fix a minor memory leak when getting GSettingsAction:state
    
    Signed-off-by: Philip Withnall <pwithnall endlessos org>

 gio/gsettings.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gio/gsettings.c b/gio/gsettings.c
index 4332ebe44..9a04a8630 100644
--- a/gio/gsettings.c
+++ b/gio/gsettings.c
@@ -3296,7 +3296,7 @@ g_settings_action_get_property (GObject *object, guint prop_id,
       break;
 
     case ACTION_PROP_STATE:
-      g_value_set_variant (value, g_settings_action_get_state (action));
+      g_value_take_variant (value, g_settings_action_get_state (action));
       break;
 
     default:


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