ecore_main: don't wait on marked to delete handlers on Windows

This could lead to greedy wait with 100% CPU consumption because on wait
error we never reach actual handlers deletion.
This commit is contained in:
Andrii Kroitor 2016-12-27 15:52:30 +02:00
parent f967c4dea5
commit ea66c8302a
1 changed files with 6 additions and 0 deletions

View File

@ -2598,6 +2598,9 @@ _ecore_main_win32_select(int nfds EINA_UNUSED,
/* Create an event object per socket */
EINA_INLIST_FOREACH(fd_handlers, fdh)
{
if (fdh->delete_me)
continue;
WSAEVENT event;
long network_event;
@ -2632,6 +2635,9 @@ _ecore_main_win32_select(int nfds EINA_UNUSED,
/* store the HANDLEs in the objects to wait for */
EINA_INLIST_FOREACH(win32_handlers, wh)
{
if (wh->delete_me)
continue;
if (wh->h == stdin_handle)
{
if (stdin_wait_thread == INVALID_HANDLE_VALUE)