mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice
synced 2026-01-11 08:07:16 +00:00
tree: Use GLib memory functions
Signed-off-by: Frediano Ziglio <fziglio@redhat.com> Acked-by: Jonathon Jongsma <jjongsma@redhat.com>
This commit is contained in:
parent
04bc835326
commit
9f4a54eb88
@ -195,7 +195,7 @@ Shadow* shadow_new(DrawItem *item, const SpicePoint *delta)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Shadow *shadow = spice_new(Shadow, 1);
|
||||
Shadow *shadow = g_new(Shadow, 1);
|
||||
|
||||
shadow->base.type = TREE_ITEM_TYPE_SHADOW;
|
||||
shadow->base.container = NULL;
|
||||
@ -215,7 +215,7 @@ Shadow* shadow_new(DrawItem *item, const SpicePoint *delta)
|
||||
* container */
|
||||
Container* container_new(DrawItem *item)
|
||||
{
|
||||
Container *container = spice_new(Container, 1);
|
||||
Container *container = g_new(Container, 1);
|
||||
|
||||
container->base.type = TREE_ITEM_TYPE_CONTAINER;
|
||||
container->base.container = item->base.container;
|
||||
@ -237,7 +237,7 @@ void container_free(Container *container)
|
||||
|
||||
ring_remove(&container->base.siblings_link);
|
||||
region_destroy(&container->base.rgn);
|
||||
free(container);
|
||||
g_free(container);
|
||||
}
|
||||
|
||||
void container_cleanup(Container *container)
|
||||
@ -308,5 +308,5 @@ void draw_item_remove_shadow(DrawItem *item)
|
||||
ring_remove(&shadow->base.siblings_link);
|
||||
region_destroy(&shadow->base.rgn);
|
||||
region_destroy(&shadow->on_hold);
|
||||
free(shadow);
|
||||
g_free(shadow);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user