summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2021-05-05 19:44:01 +0100
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2021-05-05 19:44:34 +0100
commit9fab234064db56234918f76faa0afbf8e21c7e72 (patch)
treeb9d0b120211a84d265875aec6846c35f0b061b95 /src
parent032e86f4aaf4d7972477849bb372da4a3c0ea8ea (diff)
evas - fix seg on setting immage src if invalid obj
@fix
Diffstat (limited to 'src')
-rw-r--r--src/lib/evas/canvas/efl_canvas_proxy.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/lib/evas/canvas/efl_canvas_proxy.c b/src/lib/evas/canvas/efl_canvas_proxy.c
index 9f626868e9..d55cbc2c31 100644
--- a/src/lib/evas/canvas/efl_canvas_proxy.c
+++ b/src/lib/evas/canvas/efl_canvas_proxy.c
@@ -8,6 +8,11 @@ _evas_image_proxy_source_set(Eo *eo_obj, Evas_Object *eo_src)
8{ 8{
9 Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, EFL_CANVAS_OBJECT_CLASS); 9 Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, EFL_CANVAS_OBJECT_CLASS);
10 Evas_Image_Data *o = efl_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS); 10 Evas_Image_Data *o = efl_data_scope_get(eo_obj, EFL_CANVAS_IMAGE_INTERNAL_CLASS);
11 if (!obj)
12 {
13 WRN("Image source %p not valid", eo_obj);
14 return EINA_FALSE;
15 }
11 if (obj->delete_me && eo_src) 16 if (obj->delete_me && eo_src)
12 { 17 {
13 WRN("Setting deleted object %p as image source %p", eo_src, eo_obj); 18 WRN("Setting deleted object %p as image source %p", eo_src, eo_obj);
@@ -16,6 +21,11 @@ _evas_image_proxy_source_set(Eo *eo_obj, Evas_Object *eo_src)
16 if (eo_src) 21 if (eo_src)
17 { 22 {
18 Evas_Object_Protected_Data *src = efl_data_scope_get(eo_src, EFL_CANVAS_OBJECT_CLASS); 23 Evas_Object_Protected_Data *src = efl_data_scope_get(eo_src, EFL_CANVAS_OBJECT_CLASS);
24 if (!src)
25 {
26 WRN("Setting object %p not valid", eo_src);
27 return EINA_FALSE;
28 }
19 if (src->delete_me) 29 if (src->delete_me)
20 { 30 {
21 WRN("Setting object %p to deleted image source %p", eo_src, eo_obj); 31 WRN("Setting object %p to deleted image source %p", eo_src, eo_obj);