discomfitor pushed a commit to branch enlightenment-0.22.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=5af9485c4f5d4aa97def122d651bc6d29fb0b149

commit 5af9485c4f5d4aa97def122d651bc6d29fb0b149
Author: Chris Michael <devilho...@comcast.net>
Date:   Wed Jul 25 14:59:36 2018 -0400

    enlightenment: Ensure we have a valid menu comp object before calling
    
    Summary:
    evas functions
    
    This fixes an issue when quickly mousing through menus can cause a
    segfault in Enlightenment due to menu->comp_object being NULL
    
    ref T7030
    
    Reviewers: zmike
    
    Reviewed By: zmike
    
    Subscribers: cedric
    
    Tags: #efl, #enlightenment22
    
    Maniphest Tasks: T7030
    
    Differential Revision: https://phab.enlightenment.org/D6641
---
 src/bin/e_menu.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/src/bin/e_menu.c b/src/bin/e_menu.c
index bbcb0a10f..7d2c458b4 100644
--- a/src/bin/e_menu.c
+++ b/src/bin/e_menu.c
@@ -1175,10 +1175,14 @@ e_menu_idler_before(void)
    /* phase 4. de-activate... */
    EINA_LIST_REVERSE_FOREACH(_e_active_menus, l, m)
      {
-        if ((!m->active) && (!evas_object_visible_get(m->comp_object)))
+        if (!m->active)
           {
-             _e_menu_unrealize(m);
-             removals = eina_list_append(removals, m);
+             if ((m->realized) &&
+                 (!evas_object_visible_get(m->comp_object)))
+               {
+                  _e_menu_unrealize(m);
+                  removals = eina_list_append(removals, m);
+               }
           }
      }
    EINA_LIST_FREE(removals, m)

-- 


Reply via email to