forked from enlightenment/efl
ecore-wl2: Fix event processing for client connections
Signed-off-by: Chris Michael <cp.michael@samsung.com>
This commit is contained in:
parent
5a13b093b5
commit
59d1491929
|
@ -193,19 +193,27 @@ _cb_connect_data(void *data, Ecore_Fd_Handler *hdl)
|
|||
}
|
||||
|
||||
if (ecore_main_fd_handler_active_get(hdl, ECORE_FD_READ))
|
||||
{
|
||||
ret = wl_display_dispatch(ewd->wl.display);
|
||||
else if (ecore_main_fd_handler_active_get(hdl, ECORE_FD_WRITE))
|
||||
if ((ret < 0) && ((errno != EAGAIN) && (errno != EINVAL)))
|
||||
{
|
||||
/* TODO: handle error case */
|
||||
return ECORE_CALLBACK_CANCEL;
|
||||
}
|
||||
}
|
||||
|
||||
if (ecore_main_fd_handler_active_get(hdl, ECORE_FD_WRITE))
|
||||
{
|
||||
ret = wl_display_flush(ewd->wl.display);
|
||||
if (ret == 0)
|
||||
ecore_main_fd_handler_active_set(hdl, ECORE_FD_READ);
|
||||
}
|
||||
|
||||
if ((ret < 0) && ((errno != EAGAIN) && (errno != EINVAL)))
|
||||
{
|
||||
/* TODO: handle error case */
|
||||
return ECORE_CALLBACK_CANCEL;
|
||||
}
|
||||
}
|
||||
|
||||
return ECORE_CALLBACK_RENEW;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue