cedric pushed a commit to branch enlightenment-0.17.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=7e69a6d5d48810a05c0a9033011d1df2b2bd14b8

commit 7e69a6d5d48810a05c0a9033011d1df2b2bd14b8
Author: wonguk.jeong <wonguk.je...@samsung.com>
Date:   Mon May 26 15:11:13 2014 +0900

    everything: delete mouse event handlers on selector_free
    
    Summary:
    Since mouse up handler is invoked after selector_free, there was a crash.
    
    reproduce: double click on selector area (tabbar area on top) to launch app 
-> SEGV
    
    Fixes T1264
    
    Test Plan: enlightenment -> everything -> double click on selector area 
(tabbar on top)
    
    Reviewers: raster, zmike
    
    CC: seoz, cedric
    
    Maniphest Tasks: T1264
    
    Differential Revision: https://phab.enlightenment.org/D886
---
 src/modules/everything/evry.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/src/modules/everything/evry.c b/src/modules/everything/evry.c
index 1235940..bd3e486 100644
--- a/src/modules/everything/evry.c
+++ b/src/modules/everything/evry.c
@@ -1162,6 +1162,17 @@ static void
 _evry_selector_free(Evry_Selector *sel)
 {
    Evry_Window *win = sel->win;
+   Evas_Object *o;
+
+   if ((o = edje_object_part_swallow_get(win->o_main, sel->edje_part)))
+     {
+        evas_object_event_callback_del_full(o, EVAS_CALLBACK_MOUSE_DOWN,
+                                       _evry_selector_cb_down, sel);
+        evas_object_event_callback_del_full(o, EVAS_CALLBACK_MOUSE_UP,
+                                       _evry_selector_cb_up, sel);
+        evas_object_event_callback_del_full(o, EVAS_CALLBACK_MOUSE_WHEEL,
+                                       _evry_selector_cb_wheel, sel);
+     }
 
    _evry_selector_item_clear(sel);
 

-- 


Reply via email to