[glib] resources: tests: Plug a mem leak



commit 108e11875e74c9c9483cab1a8f72e432bdbb8004
Author: Christian Persch <chpe gnome org>
Date:   Sun Feb 5 16:14:21 2012 +0100

    resources: tests: Plug a mem leak
    
    ==28318== 38 (12 direct, 26 indirect) bytes in 1 blocks are definitely lost in loss record 613 of 865
    ==28318==    at 0x402AD89: malloc (vg_replace_malloc.c:236)
    ==28318==    by 0x4084724: standard_malloc (gmem.c:85)
    ==28318==    by 0x40847C7: g_malloc (gmem.c:159)
    ==28318==    by 0x4084AB4: g_malloc_n (gmem.c:361)
    ==28318==    by 0x4229599: g_resources_enumerate_children (gresource.c:806)
    ==28318==    by 0x804B39E: test_resource_registred (resources.c:283)

 gio/tests/resources.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
---
diff --git a/gio/tests/resources.c b/gio/tests/resources.c
index 73229c0..84ab854 100644
--- a/gio/tests/resources.c
+++ b/gio/tests/resources.c
@@ -286,6 +286,7 @@ test_resource_registred (void)
   g_assert (children != NULL);
   g_assert_no_error (error);
   g_assert_cmpint (g_strv_length (children), ==, 2);
+  g_strfreev (children);
 
   g_resources_unregister (resource);
 



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