mirror of https://github.com/GNOME/gimp.git
use GSlice to allocate the transform matrix.
2007-05-29 Sven Neumann <sven@gimp.org> * app/tools/gimpdrawtool.c: use GSlice to allocate the transform matrix. svn path=/trunk/; revision=22652
This commit is contained in:
parent
b19ebc29f9
commit
2027fdf9ab
|
@ -1,3 +1,8 @@
|
||||||
|
2007-05-29 Sven Neumann <sven@gimp.org>
|
||||||
|
|
||||||
|
* app/tools/gimpdrawtool.c: use GSlice to allocate the transform
|
||||||
|
matrix.
|
||||||
|
|
||||||
2007-05-29 Sven Neumann <sven@gimp.org>
|
2007-05-29 Sven Neumann <sven@gimp.org>
|
||||||
|
|
||||||
* app/vectors/gimpvectors-import.c: don't memdup gslice-allocated
|
* app/vectors/gimpvectors-import.c: don't memdup gslice-allocated
|
||||||
|
|
|
@ -118,7 +118,7 @@ gimp_draw_tool_finalize (GObject *object)
|
||||||
|
|
||||||
if (draw_tool->transform)
|
if (draw_tool->transform)
|
||||||
{
|
{
|
||||||
g_free (draw_tool->transform);
|
g_slice_free (GimpMatrix3, draw_tool->transform);
|
||||||
draw_tool->transform = NULL;
|
draw_tool->transform = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -346,12 +346,15 @@ gimp_draw_tool_set_transform (GimpDrawTool *draw_tool,
|
||||||
|
|
||||||
if (draw_tool->transform)
|
if (draw_tool->transform)
|
||||||
{
|
{
|
||||||
g_free (draw_tool->transform);
|
g_slice_free (GimpMatrix3, draw_tool->transform);
|
||||||
draw_tool->transform = NULL;
|
draw_tool->transform = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (transform)
|
if (transform)
|
||||||
draw_tool->transform = g_memdup (transform, sizeof (GimpMatrix3));
|
{
|
||||||
|
draw_tool->transform = g_slice_new (GimpMatrix3);
|
||||||
|
memcpy (draw_tool->transform, transform, sizeof (GimpMatrix3));
|
||||||
|
}
|
||||||
|
|
||||||
gimp_draw_tool_resume (draw_tool);
|
gimp_draw_tool_resume (draw_tool);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue