summaryrefslogtreecommitdiff
path: root/src/lib/ecore
diff options
context:
space:
mode:
authorWooHyun Jung <wh0705.jung@samsung.com>2017-07-26 18:57:37 +0900
committerWooHyun Jung <wh0705.jung@samsung.com>2017-07-26 18:57:37 +0900
commit9ef214ec0890116881fe79bc151c4ffa6b1fac83 (patch)
tree1fba137509cce43627b71a52f586257ac2538d7e /src/lib/ecore
parent6d4ebf9bc696b59fc94a711a1d3332791efab90c (diff)
ecore_events: inarray should be flushed before return
@fix
Diffstat (limited to 'src/lib/ecore')
-rw-r--r--src/lib/ecore/ecore_events.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/lib/ecore/ecore_events.c b/src/lib/ecore/ecore_events.c
index 24a76bf457..3b13ef9015 100644
--- a/src/lib/ecore/ecore_events.c
+++ b/src/lib/ecore/ecore_events.c
@@ -616,13 +616,13 @@ ecore_event_type_flush_internal(int type, ...)
616 va_list args; 616 va_list args;
617 Eina_Bool wrong_type = EINA_FALSE; 617 Eina_Bool wrong_type = EINA_FALSE;
618 618
619 // In case of an empty list of event
620 if (type == ECORE_EVENT_NONE) return;
621
619 eina_inarray_step_set(&types, sizeof (Eina_Inarray), sizeof (int), 4); 622 eina_inarray_step_set(&types, sizeof (Eina_Inarray), sizeof (int), 4);
620 623
621 eina_inarray_push(&types, &type); 624 eina_inarray_push(&types, &type);
622 625
623 // In case of an empty list of event
624 if (type == ECORE_EVENT_NONE) return;
625
626 va_start(args, type); 626 va_start(args, type);
627 do 627 do
628 { 628 {
@@ -641,7 +641,11 @@ ecore_event_type_flush_internal(int type, ...)
641 wrong_type = EINA_TRUE; 641 wrong_type = EINA_TRUE;
642 } 642 }
643 643
644 if (wrong_type) return ; 644 if (wrong_type)
645 {
646 eina_inarray_flush(&types);
647 return ;
648 }
645 649
646 EINA_INLIST_FOREACH_SAFE((Eina_Inlist *) events, l, event) 650 EINA_INLIST_FOREACH_SAFE((Eina_Inlist *) events, l, event)
647 { 651 {