tests: Fix leak in appmonitor test

Spotted by Daniel Macks.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

https://bugzilla.gnome.org/show_bug.cgi?id=785260
This commit is contained in:
Philip Withnall 2017-08-18 09:37:23 +01:00
parent 2586eb9921
commit 3ce00b29ec

View File

@ -97,11 +97,12 @@ test_app_monitor (void)
int
main (int argc, char *argv[])
{
gchar *path;
gchar *path = NULL;
path = g_mkdtemp (g_strdup ("app_monitor_XXXXXX"));
g_setenv ("XDG_DATA_DIRS", path, TRUE);
g_setenv ("XDG_DATA_HOME", path, TRUE);
g_free (path);
g_test_init (&argc, &argv, NULL);