aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJongMin Lee <jm105.lee@samsung.com>2018-04-27 14:14:37 +0900
committerHermet Park <hermetpark@gmail.com>2018-04-27 14:14:37 +0900
commit4092c3a554ccfb2bd841f0b15b24c19dfe3be970 (patch)
tree8fe6cafacd0a465080ce405daab446c6ae0226e2
parentelm efl_selection_manager: resolve possible memory leak. (diff)
downloadefl-4092c3a554ccfb2bd841f0b15b24c19dfe3be970.tar.gz
evas: resolve possible memory leak.
-rw-r--r--src/lib/evas/canvas/evas_out.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/lib/evas/canvas/evas_out.c b/src/lib/evas/canvas/evas_out.c
index a1a35a1276..40cce4ce04 100644
--- a/src/lib/evas/canvas/evas_out.c
+++ b/src/lib/evas/canvas/evas_out.c
@@ -53,7 +53,13 @@ efl_canvas_output_add(Evas *canvas)
r->changed = EINA_TRUE;
e = _efl_canvas_output_async_block(r);
- if (!e) return NULL;
+ if (!e)
+ {
+ efl_wref_del(canvas, &r->canvas);
+ free(r);
+ return NULL;
+ }
+
// Track this output in Evas
e->outputs = eina_list_append(e->outputs, r);