Before we returned the number of async events handled.
Even if nobody uses that let's fix it.
SVN revision: 82775
int ret, wakeup;
ret = read(_fd_read, &wakeup, sizeof(int));
+ if (ret < 0)
+ {
+ switch (errno)
+ {
+ case EBADF:
+ case EINVAL:
+ case EIO:
+ case EISDIR:
+ _fd_read = -1;
+ }
+
+ return ret;
+ }
+
if (ret == sizeof(int))
{
Evas_Event_Async *ev;
unsigned int len, max;
+ int nr;
eina_lock_take(&async_lock);
eina_lock_release(&async_lock);
DBG("Evas async events queue length: %u", len);
+ nr = len;
while (len > 0)
{
len--;
}
- return 1;
+ return nr;
}
- if (ret < 0)
- {
- switch (errno)
- {
- case EBADF:
- case EINVAL:
- case EIO:
- case EISDIR:
- _fd_read = -1;
- }
- }
-
- return ret;
+ return 0;
}
EAPI int