tests: Fix GOptionContext leak in GSubprocess tests

This commit is contained in:
Tomasz Miąsko 2018-11-01 00:00:00 +00:00
parent 9347c7630f
commit 52bab0254a

View File

@ -205,10 +205,13 @@ main (int argc, char **argv)
g_option_context_add_main_entries (context, options, NULL);
if (!g_option_context_parse (context, &argc, &argv, &error))
{
g_option_context_free (context);
g_printerr ("%s: %s\n", argv[0], error->message);
return 1;
}
g_option_context_free (context);
if (argc < 2)
{
g_printerr ("MODE argument required\n");