mirror of https://github.com/GNOME/gimp.git
plug leak introduced with last commit: simply always use the deserialized
2007-02-11 Michael Natterer <mitch@gimp.org> * app/core/gimpcontainer.c (gimp_container_deserialize): plug leak introduced with last commit: simply always use the deserialized name, also on ojects already existing in the container. svn path=/trunk/; revision=21890
This commit is contained in:
parent
287331b36f
commit
b1093d65a3
|
@ -1,3 +1,9 @@
|
|||
2007-02-11 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* app/core/gimpcontainer.c (gimp_container_deserialize): plug leak
|
||||
introduced with last commit: simply always use the deserialized
|
||||
name, also on ojects already existing in the container.
|
||||
|
||||
2007-02-10 Sven Neumann <sven@gimp.org>
|
||||
|
||||
* modules/controller_linux_input.c
|
||||
|
|
|
@ -431,32 +431,18 @@ gimp_container_deserialize (GimpConfig *config,
|
|||
if (! child)
|
||||
{
|
||||
if (GIMP_IS_GIMP (data))
|
||||
{
|
||||
child = g_object_new (type,
|
||||
"name", name,
|
||||
"gimp", data, NULL);
|
||||
}
|
||||
child = g_object_new (type, "gimp", data, NULL);
|
||||
else
|
||||
{
|
||||
child = g_object_new (type,
|
||||
"name", name, NULL);
|
||||
}
|
||||
child = g_object_new (type, NULL);
|
||||
|
||||
add_child = TRUE;
|
||||
}
|
||||
else if (strcmp (name, gimp_object_get_name (child)))
|
||||
{
|
||||
/* we found the child by name, but the name isn't the same?
|
||||
* this must be an obscure case like template migration,
|
||||
* so set the deserialized name on the already existing
|
||||
* object.
|
||||
*/
|
||||
gimp_object_take_name (child, name);
|
||||
}
|
||||
else
|
||||
{
|
||||
g_free (name);
|
||||
}
|
||||
|
||||
/* always use the deserialized name. while it normally
|
||||
* doesn't make a difference there are obscure case like
|
||||
* template migration.
|
||||
*/
|
||||
gimp_object_take_name (child, name);
|
||||
|
||||
if (! GIMP_CONFIG_GET_INTERFACE (child)->deserialize (GIMP_CONFIG (child),
|
||||
scanner,
|
||||
|
|
Loading…
Reference in New Issue