libgimp: no need to set NULL strings on GimpPDBProcedure

This commit is contained in:
Michael Natterer 2019-09-09 00:35:56 +02:00
parent 5f60f5422b
commit 5a57256a24
1 changed files with 10 additions and 4 deletions

View File

@ -230,12 +230,18 @@ _gimp_pdb_procedure_new (GimpPDB *pdb,
gint i; gint i;
string = _gimp_pdb_get_proc_image_types (name); string = _gimp_pdb_get_proc_image_types (name);
gimp_procedure_set_image_types (procedure, string); if (string)
g_free (string); {
gimp_procedure_set_image_types (procedure, string);
g_free (string);
}
string = _gimp_pdb_get_proc_menu_label (name); string = _gimp_pdb_get_proc_menu_label (name);
gimp_procedure_set_menu_label (procedure, string); if (string)
g_free (string); {
gimp_procedure_set_menu_label (procedure, string);
g_free (string);
}
menu_paths = _gimp_pdb_get_proc_menu_paths (name, &n_menu_paths); menu_paths = _gimp_pdb_get_proc_menu_paths (name, &n_menu_paths);
for (i = 0; i < n_menu_paths; i++) for (i = 0; i < n_menu_paths; i++)