plug-ins/script-fu/script-fu-scripts.c use GSlice to allocate structs.

2007-05-22  Sven Neumann  <sven@gimp.org>

	* plug-ins/script-fu/script-fu-scripts.c
	* plug-ins/script-fu/script-fu-interface.c: use GSlice to allocate
	structs.

svn path=/trunk/; revision=22568
This commit is contained in:
Sven Neumann
2007-05-22 14:20:08 +00:00
committed by Sven Neumann
parent ba25863e49
commit 017ff2e06d
3 changed files with 14 additions and 11 deletions

View File

@ -209,7 +209,8 @@ script_fu_interface (SFScript *script,
gtk_initted = TRUE;
}
sf_interface = g_new0 (SFInterface, 1);
sf_interface = g_slice_new0 (SFInterface);
sf_interface->widgets = g_new0 (GtkWidget *, script->num_args);
/* strip mnemonics from the menupath */
@ -631,7 +632,7 @@ script_fu_interface_quit (SFScript *script)
g_free (sf_interface->widgets);
g_free (sf_interface->last_command);
g_free (sf_interface);
g_slice_free (SFInterface, sf_interface);
sf_interface = NULL;
/*