[mutter] shaped-texture: Clean up texture regions
- From: Jonas Ådahl <jadahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] shaped-texture: Clean up texture regions
- Date: Sun, 21 Oct 2018 11:07:05 +0000 (UTC)
commit 8200995fdbf04b2763d33cd30d7c8174eebc1736
Author: Jonas Ådahl <jadahl gmail com>
Date: Sat Oct 20 15:47:50 2018 +0200
shaped-texture: Clean up texture regions
We allocated texture regions, but didn't free them when finished,
causing a leak.
https://gitlab.gnome.org/GNOME/gnome-shell/issues/653
src/compositor/meta-shaped-texture.c | 3 +++
1 file changed, 3 insertions(+)
---
diff --git a/src/compositor/meta-shaped-texture.c b/src/compositor/meta-shaped-texture.c
index 5328a919e..cd151a28e 100644
--- a/src/compositor/meta-shaped-texture.c
+++ b/src/compositor/meta-shaped-texture.c
@@ -516,6 +516,7 @@ meta_shaped_texture_paint (ClutterActor *actor)
}
else
{
+ opaque_tex_region = NULL;
use_opaque_region = FALSE;
}
@@ -659,6 +660,8 @@ meta_shaped_texture_paint (ClutterActor *actor)
}
}
+ g_clear_pointer (&clip_tex_region, cairo_region_destroy);
+ g_clear_pointer (&opaque_tex_region, cairo_region_destroy);
g_clear_pointer (&blended_tex_region, cairo_region_destroy);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]