summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lib/ecore/ecore_timer.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/src/lib/ecore/ecore_timer.c b/src/lib/ecore/ecore_timer.c
index 1b69676e54..54cf773149 100644
--- a/src/lib/ecore/ecore_timer.c
+++ b/src/lib/ecore/ecore_timer.c
@@ -157,14 +157,8 @@ _ecore_timer_legacy_tick(void *data, const Eo_Event *event)
157 157
158 if (!_ecore_call_task_cb(legacy->func, (void*)legacy->data)) 158 if (!_ecore_call_task_cb(legacy->func, (void*)legacy->data))
159 { 159 {
160 if (eo_key_data_get(event->obj, "_legacy")) 160 eo_del(event->obj);
161 { 161 free(legacy);
162 eo_key_del(event->obj, "_legacy");
163 eo_event_callback_del(event->obj, EFL_TIMER_EVENT_TICK,
164 _ecore_timer_legacy_tick, legacy),
165 free(legacy);
166 eo_del(event->obj);
167 }
168 } 162 }
169 163
170 return EO_CALLBACK_CONTINUE; 164 return EO_CALLBACK_CONTINUE;
@@ -225,10 +219,8 @@ ecore_timer_del(Ecore_Timer *timer)
225 legacy = eo_key_data_get(timer, "_legacy"); 219 legacy = eo_key_data_get(timer, "_legacy");
226 data = (void*) legacy->data; 220 data = (void*) legacy->data;
227 221
228 eo_key_del(timer, "_legacy");
229 eo_event_callback_del(timer, EFL_TIMER_EVENT_TICK,
230 _ecore_timer_legacy_tick, legacy),
231 free(legacy); 222 free(legacy);
223 eo_key_del(timer, "_legacy");
232 eo_del(timer); 224 eo_del(timer);
233 225
234 return data; 226 return data;