aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules/evas
diff options
context:
space:
mode:
authorDongyeon Kim <dy5.kim@samsung.com>2015-10-01 10:05:28 +0900
committerDongyeon Kim <dy5.kim@samsung.com>2015-10-01 10:05:28 +0900
commitb6649f6c6e18aebd0e8a7a8db8e0df931129b0cf (patch)
treed0238a755b3e670210c86084e5ea03b9ad234068 /src/modules/evas
parenteolian-cxx: Fix inheritance from C++ classes after Eo ABI breakage (diff)
downloadefl-b6649f6c6e18aebd0e8a7a8db8e0df931129b0cf.tar.gz
evas/gl_common: Fix memory leak for font glyph extension image
Evas_GL_Image created for font glyphs in evas_common_font_rgba_draw is sometimes freed after Evas_Engine_GL_Context is freed. Since gc is already freed, pt_unref returns and leaves pt behind.
Diffstat (limited to 'src/modules/evas')
-rw-r--r--src/modules/evas/engines/gl_common/evas_gl_texture.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/modules/evas/engines/gl_common/evas_gl_texture.c b/src/modules/evas/engines/gl_common/evas_gl_texture.c
index f2451c3c5f..f0eb72264b 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_texture.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_texture.c
@@ -946,11 +946,10 @@ void
pt_unref(Evas_GL_Texture_Pool *pt)
{
if (!pt) return;
- if (!pt->gc) return;
pt->references--;
if (pt->references != 0) return;
- if (!((pt->render) || (pt->native)))
+ if ((pt->gc) && !((pt->render) || (pt->native)))
{
if (pt->whole)
pt->gc->shared->tex.whole =