From 70a3b71abaea38839da21247a86c483ae12bc783 Mon Sep 17 00:00:00 2001 From: "Carsten Haitzler (Rasterman)" Date: Tue, 9 Jul 2019 13:03:31 +0100 Subject: [PATCH] elm - cursor - clear cursor job late to avoid crash during cursor free a move cb seems to add another job again after it wss already deleted during the free process, so just clear the job really late instead. valgrind found this one @fix --- src/lib/elementary/els_cursor.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/lib/elementary/els_cursor.c b/src/lib/elementary/els_cursor.c index cf4bc7642c..eeb1d18f85 100644 --- a/src/lib/elementary/els_cursor.c +++ b/src/lib/elementary/els_cursor.c @@ -698,9 +698,6 @@ elm_object_cursor_unset(Evas_Object *obj) { ELM_CURSOR_GET_OR_RETURN(cur, obj); - if (cur->hotupdate_job) ecore_job_del(cur->hotupdate_job); - cur->hotupdate_job = NULL; - eina_stringshare_del(cur->cursor_name); cur->cursor_name = NULL; eina_stringshare_del(cur->style); @@ -754,6 +751,10 @@ elm_object_cursor_unset(Evas_Object *obj) evas_object_event_callback_del_full(obj, EVAS_CALLBACK_DEL, _elm_cursor_del, cur); evas_object_data_del(obj, _cursor_key); + + if (cur->hotupdate_job) ecore_job_del(cur->hotupdate_job); + cur->hotupdate_job = NULL; + free(cur); }