GitLab repository storage has been migrated to hashed layout. Please contact Infrastructure team if you notice any issues with repositories or hooks.

Commit 5db7fbc8 authored by Matthias Clasen's avatar Matthias Clasen

Fix another leak

svn path=/trunk/; revision=17050
parent 4e332f0d
2007-01-03 Matthias Clasen <mclasen@redhat.com>
* modules/printbackends/cups/gtkprintbackendcups.c
(available_choices): Don't leak conflicts.
* gtk/gtkprintoperation.c (gtk_print_operation_finalize):
Don't leak the status string.
......
......@@ -1786,12 +1786,13 @@ available_choices (ppd_file_t *ppd,
all_default = FALSE;
}
if (all_default && !keep_if_only_one_option)
return 0;
if (num_conflicts == option->num_choices)
return 0;
if ((all_default && !keep_if_only_one_option) ||
(num_conflicts == option->num_choices))
{
g_free (conflicts);
return 0;
}
/* Some ppds don't have a "use printer default" option for
* InputSlot. This means you always have to select a particular slot,
......@@ -1830,7 +1831,6 @@ available_choices (ppd_file_t *ppd,
if (available)
{
*available = g_new (ppd_choice_t *, option->num_choices - num_conflicts + add_auto);
i = 0;
......@@ -1843,6 +1843,8 @@ available_choices (ppd_file_t *ppd,
if (add_auto)
(*available)[i++] = NULL;
}
g_free (conflicts);
return option->num_choices - num_conflicts + add_auto;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment