diff options
author | Adel Gadllah <adel.gadllah@gmail.com> | 2011-09-29 15:16:33 +0200 |
---|---|---|
committer | Adel Gadllah <adel.gadllah@gmail.com> | 2011-09-29 15:36:10 +0200 |
commit | 1b4dce6f843d50fbc9b0fa8f86527788fb0c29d7 (patch) | |
tree | 306aea02cca43cad9c53d541b84038deebb06036 | |
parent | 3bb17f06710d50ca833c755ab724f2d1aaf5a067 (diff) | |
download | mutter-1b4dce6f843d50fbc9b0fa8f86527788fb0c29d7.tar.gz |
meta-window-group: Plug memory leak
We have to free the list returned by clutter_actor_get_effects() .
https://bugzilla.gnome.org/show_bug.cgi?id=660464
-rw-r--r-- | src/compositor/meta-window-group.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/compositor/meta-window-group.c b/src/compositor/meta-window-group.c index 107e7ba51..888950392 100644 --- a/src/compositor/meta-window-group.c +++ b/src/compositor/meta-window-group.c @@ -108,7 +108,7 @@ meta_window_group_paint (ClutterActor *actor) cairo_region_t *unredirected_window_region = NULL; ClutterActor *stage; cairo_rectangle_int_t visible_rect, unredirected_rect; - GList *children, *l; + GList *children, *l, *effects; MetaWindowGroup *window_group = META_WINDOW_GROUP (actor); MetaCompScreen *info = meta_screen_get_compositor_data (window_group->screen); @@ -161,8 +161,11 @@ meta_window_group_paint (ClutterActor *actor) * as well for the same reason, but omitted for simplicity in the * hopes that no-one will do that. */ - if (clutter_actor_get_effects (l->data) != NULL) - continue; + if ((effects = clutter_actor_get_effects (l->data)) != NULL) + { + g_list_free (effects); + continue; + } if (META_IS_WINDOW_ACTOR (l->data)) { |