[gnome-keyring] test-startup: Use g_strfreev to free GStrv variable



commit 1e18f347a1a3444b3fc7126af087d0c90a791e57
Author: Christophe Fergeau <cfergeau redhat com>
Date:   Wed Oct 1 22:34:09 2014 +0200

    test-startup: Use g_strfreev to free GStrv variable
    
    gkd_test_launch_daemon returns a "transfer full" GStrv, so it must be
    freed with g_strfreev after use.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=738508

 daemon/test-startup.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/daemon/test-startup.c b/daemon/test-startup.c
index af63ad6..da11b42 100644
--- a/daemon/test-startup.c
+++ b/daemon/test-startup.c
@@ -232,13 +232,13 @@ test_daemon_replace (Test *test,
        output = gkd_test_launch_daemon (test->directory, argv, &pid,
                                         "XDG_RUNTIME_DIR", "/tmp/keyring-test-two",
                                         NULL);
-       g_free (output);
+       g_strfreev (output);
 
        /* Replace with the second daemon */
        output = gkd_test_launch_daemon (test->directory, replace, &test->pid,
                                         "XDG_RUNTIME_DIR", "/tmp/keyring-test-two",
                                         NULL);
-       g_free (output);
+       g_strfreev (output);
 
        /* The first daemon should have exited cleanly here */
        g_assert_cmpint (waitpid (pid, &status, 0), ==, pid);


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