Marc Lehmann wrote:
I suspect that there simply is no place where you restart it, or stop it,
which would explain your problem.

Now all works fine.
The problem was:
ev_loop is in main thread, timers are in second thread.

When ev_loop finishes to maintain all registered timers, it waits on epoll, and epoll waits for events from sockets. When i register a new timer in the second thread, ev_loop still waits on epoll...
My timer works only in next cycle .
To resolve this problem i created a heartbeat timer in the main thread.
Another solution - is to set timeout on sockets read/write operations.

Thanks.

_______________________________________________
libev mailing list
libev@lists.schmorp.de
http://lists.schmorp.de/cgi-bin/mailman/listinfo/libev

Reply via email to