glib/tests: fix leaks

https://bugzilla.gnome.org/show_bug.cgi?id=682560
This commit is contained in:
Dan Winship
2012-08-23 12:48:49 -04:00
parent 0c0cdfd9c4
commit 1a2c5e155d
19 changed files with 574 additions and 472 deletions

View File

@@ -669,6 +669,7 @@ test_file_open_tmp (void)
g_assert_no_error (error);
g_assert (name != NULL);
unlink (name);
g_free (name);
close (fd);
fd = g_file_open_tmp (NULL, &name, &error);
@@ -676,6 +677,7 @@ test_file_open_tmp (void)
g_assert_no_error (error);
g_assert (name != NULL);
g_unlink (name);
g_free (name);
close (fd);
name = NULL;