mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-26 04:02:09 +01:00
tests: fix leak in mainloop test
Properly unref a pair of GSources in the unix-fd mainloop test. valgrind was reporting these as 'still reachable' before (possibly due to some residual pointers somewhere in memory), but when running with G_DEBUG=cleanup they were properly reported as leaked.
This commit is contained in:
parent
eef0d3c0b8
commit
92b71825fd
@ -1273,7 +1273,9 @@ test_unix_fd_source (void)
|
|||||||
g_assert (in && out);
|
g_assert (in && out);
|
||||||
|
|
||||||
g_source_destroy (out_source);
|
g_source_destroy (out_source);
|
||||||
|
g_source_unref (out_source);
|
||||||
g_source_destroy (in_source);
|
g_source_destroy (in_source);
|
||||||
|
g_source_unref (in_source);
|
||||||
close (fds[1]);
|
close (fds[1]);
|
||||||
close (fds[0]);
|
close (fds[0]);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user