[network-manager-applet/nma-1-2] applet: fix crash in applet-agent.c



commit ab3659284ea7cca3086746c81c2060eead05d8c8
Author: Beniamino Galvani <bgalvani redhat com>
Date:   Mon Jun 6 14:26:45 2016 +0200

    applet: fix crash in applet-agent.c
    
    '@' must be prepended to format string in order to get a GVariant.
    
    Fixes: 3722a190468f5ce5898db8838611bc826d3153f1
    
    https://bugzilla.gnome.org/show_bug.cgi?id=765089
    (cherry picked from commit 91d83b708c599f89079ad108898e20696fc3448b)

 src/applet-agent.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/applet-agent.c b/src/applet-agent.c
index 1dcb085..465d44d 100644
--- a/src/applet-agent.c
+++ b/src/applet-agent.c
@@ -384,11 +384,12 @@ done:
 
                /* Stuff all the found secrets into the connection for the UI to use */
                g_variant_iter_init (&dict_iter, settings);
-               while (g_variant_iter_next (&dict_iter, "{sa{sv}}", &setting_name, &setting_dict)) {
+               while (g_variant_iter_next (&dict_iter, "{s a{sv}}", &setting_name, &setting_dict)) {
                        nm_connection_update_secrets (r->connection,
                                                      setting_name,
                                                      setting_dict,
                                                      NULL);
+                       g_variant_unref (setting_dict);
                }
 
                ask_for_secrets (r);


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