On Mon, Jun 11, 2012 at 4:39 AM, 钱晓明 <mailtoanta...@163.com> wrote:
> If I have started a io_watcher with EV_READ event, but later I want to set
> EV_WRITE event in callback function of EV_READ, should I have to call
> ev_io_stop first, then ev_io_set and ev_io_start again?
> If all messages have been send, should I call ev_io_stop again, clear
> EV_WRITE event  and ev_io_start again?

It would probably be more efficient to simply register separate
callbacks for EV_READ and EV_WRITE so you can start/stop them
independently.

-- Brandon

_______________________________________________
libev mailing list
libev@lists.schmorp.de
http://lists.schmorp.de/cgi-bin/mailman/listinfo/libev
  • ev_io_set 钱晓明
    • Re: ev_io_set Brandon Black

Reply via email to