[glib/wip/gcleanup] gio-test: Fix leaks in tests



commit 9d4b9b37a534ea177c722ca8fc2f1d7f28aa83f2
Author: Stef Walter <stefw gnome org>
Date:   Sat Nov 9 20:26:15 2013 +0100

    gio-test: Fix leaks in tests

 tests/gio-test.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/tests/gio-test.c b/tests/gio-test.c
index 7c28497..06c385c 100644
--- a/tests/gio-test.c
+++ b/tests/gio-test.c
@@ -343,6 +343,7 @@ main (int    argc,
                                     pipe_to_sub[0], pipe_from_sub[1]);
          
          system (cmdline);
+          g_free (cmdline);
 #endif
          close (pipe_to_sub[0]);
          close (pipe_from_sub [1]);
@@ -359,11 +360,16 @@ main (int    argc,
                   (end.tv_usec - start.tv_usec) / 1000,
                   pollresult);
 #endif
+          g_io_channel_unref (my_read_channel);
        }
       
       main_loop = g_main_loop_new (NULL, FALSE);
       
       g_main_loop_run (main_loop);
+
+      g_main_loop_unref (main_loop);
+      g_free (seqtab);
+      g_free (id);
     }
   else if (argc == 3)
     {


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