Plug a mem leak in gsettings test

==2530== 13 bytes in 1 blocks are definitely lost in loss record 373 of 681
==2530==    at 0x4005BDC: malloc (vg_replace_malloc.c:195)
==2530==    by 0x4057094: g_malloc (gmem.c:134)
==2530==    by 0x40573DB: g_malloc_n (gmem.c:281)
==2530==    by 0x40717FC: g_strdup (gstrfuncs.c:101)
==2530==    by 0x4147F56: value_lcopy_string (gvaluetypes.c:313)
==2530==    by 0x4123F0B: g_object_get_valist (gobject.c:1643)
==2530==    by 0x41240FF: g_object_get (gobject.c:1731)
==2530==    by 0x804A4BA: test_basic (gsettings.c:28)

Bug #628331.
This commit is contained in:
Christian Persch 2010-09-03 15:29:51 -04:00 committed by Matthias Clasen
parent e8fc3ba3d0
commit 6320b04fe9

View File

@ -27,6 +27,7 @@ test_basic (void)
g_object_get (settings, "schema", &str, NULL);
g_assert_cmpstr (str, ==, "org.gtk.test");
g_free (str);
g_settings_get (settings, "greeting", "s", &str);
g_assert_cmpstr (str, ==, "Hello, earthlings");