summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCedric Bail <cedric@osg.samsung.com>2017-08-11 10:15:14 -0700
committerCedric Bail <cedric@osg.samsung.com>2017-08-11 10:18:07 -0700
commit207cab086f290878cd584e6c61b3cd2696c5fd88 (patch)
tree00335bc48dfa2567bcf8397cf777a7ba6b51fd53
parentc358ac0222c56356d4ed2d2cb722c61e67e56dec (diff)
downloadefl-207cab086f290878cd584e6c61b3cd2696c5fd88.tar.gz
evas: we should be able to access this data during an object being destroyed.
So, this is maybe not the best fix. The question is should we be able to get efl_data_scope_safe_get return the object private data, when we are currently executing the object EFL_EVENT_DEL callbacks. Right now we don't and this lead to bug where we wouldn't have been able to destroy a callback and get that callback triggered later on destroyed data (I had a crash in terminology). I have switched back to the not _safe_ version which doesn't enforce this, but that might not be the only place that need a fix.
-rw-r--r--src/lib/evas/canvas/evas_callbacks.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/evas/canvas/evas_callbacks.c b/src/lib/evas/canvas/evas_callbacks.c
index 184b500743..1ed32e5ab9 100644
--- a/src/lib/evas/canvas/evas_callbacks.c
+++ b/src/lib/evas/canvas/evas_callbacks.c
@@ -485,7 +485,7 @@ evas_object_event_callback_priority_add(Evas_Object *eo_obj, Evas_Callback_Type
EAPI void *
evas_object_event_callback_del(Evas_Object *eo_obj, Evas_Callback_Type type, Evas_Object_Event_Cb func)
{
- Evas_Object_Protected_Data *obj = efl_data_scope_safe_get(eo_obj, EFL_CANVAS_OBJECT_CLASS);
+ Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, EFL_CANVAS_OBJECT_CLASS);
Evas_Event_Cb_Wrapper_Info *info;
if (!obj) return NULL;
@@ -512,7 +512,7 @@ evas_object_event_callback_del(Evas_Object *eo_obj, Evas_Callback_Type type, Eva
EAPI void *
evas_object_event_callback_del_full(Evas_Object *eo_obj, Evas_Callback_Type type, Evas_Object_Event_Cb func, const void *data)
{
- Evas_Object_Protected_Data *obj = efl_data_scope_safe_get(eo_obj, EFL_CANVAS_OBJECT_CLASS);
+ Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, EFL_CANVAS_OBJECT_CLASS);
Evas_Event_Cb_Wrapper_Info *info;
if (!obj) return NULL;
@@ -568,7 +568,7 @@ evas_event_callback_priority_add(Evas *eo_e, Evas_Callback_Type type, Evas_Callb
EAPI void *
evas_event_callback_del(Evas *eo_e, Evas_Callback_Type type, Evas_Event_Cb func)
{
- Evas_Public_Data *e = efl_data_scope_safe_get(eo_e, EVAS_CANVAS_CLASS);
+ Evas_Public_Data *e = efl_data_scope_get(eo_e, EVAS_CANVAS_CLASS);
Evas_Event_Cb_Wrapper_Info *info;
if (!e) return NULL;
@@ -595,7 +595,7 @@ evas_event_callback_del(Evas *eo_e, Evas_Callback_Type type, Evas_Event_Cb func)
EAPI void *
evas_event_callback_del_full(Evas *eo_e, Evas_Callback_Type type, Evas_Event_Cb func, const void *data)
{
- Evas_Public_Data *e = efl_data_scope_safe_get(eo_e, EVAS_CANVAS_CLASS);
+ Evas_Public_Data *e = efl_data_scope_get(eo_e, EVAS_CANVAS_CLASS);
Evas_Event_Cb_Wrapper_Info *info;
if (!e) return NULL;