discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e263cbf9d0b867b69256673337cfe015fc2c238b

commit e263cbf9d0b867b69256673337cfe015fc2c238b
Author: Mike Blumenkrantz <[email protected]>
Date:   Fri Mar 3 11:55:44 2017 -0500

    Revert "ecore: forcefully flush pending event when ecore_shutdown is 
called."
    
    This reverts commit 2c6808e4eed28d5b93d2f10b558b168aa365364e.
    
    this breaks a number of expectations and guarantees in efl:
    
    * causes unexpected event iteration during app startup before main loop 
begins
      - leads to event loss
    * causes unexpected event iteration during app shutdown after main loop 
quits
      - leads to invalid memory access
    * causes recursive event iteration during event handler callbacks
      - leads to 
?????????????????????????????????????????????????????????????????
    
    all of these can be easily seen by running enlightenment, and all of these 
cause
    unexpected behaviors in enlightenment including, but not limited to, a lot 
of crashes
    
    fix T5232
---
 src/lib/ecore/ecore.c        | 7 -------
 src/lib/ecore/ecore_events.c | 1 +
 2 files changed, 1 insertion(+), 7 deletions(-)

diff --git a/src/lib/ecore/ecore.c b/src/lib/ecore/ecore.c
index 99ba1dd..aa5e4e4 100644
--- a/src/lib/ecore/ecore.c
+++ b/src/lib/ecore/ecore.c
@@ -355,13 +355,6 @@ ecore_shutdown(void)
           ERR("Init count not greater than 0 in shutdown.");
           return 0;
        }
-
-     // We need to flush all pending event as this is
-     // the only way to properly avoid use after free
-     // during shutdown of component that may have
-     // emitted and still pending event.
-     _ecore_event_call();
-
      if (_ecore_init_count-- != _ecore_init_count_threshold)
        goto end;
 
diff --git a/src/lib/ecore/ecore_events.c b/src/lib/ecore/ecore_events.c
index db24688..aa4bde5 100644
--- a/src/lib/ecore/ecore_events.c
+++ b/src/lib/ecore/ecore_events.c
@@ -605,3 +605,4 @@ _ecore_event_signal_realtime_new(void)
 {
    return calloc(1, sizeof(Ecore_Event_Signal_Realtime));
 }
+

-- 


Reply via email to