go to bug id or search bugs for
I've noticed that libevent has the following function:
bufferevent_setcb (struct bufferevent *bufev, evbuffercb
readcb, evbuffercb writecb, everrorcb errorcb, void *cbarg)
Changes the callbacks for a bufferevent.
Please, make wrapper to this function. It's very useful for me
and many other people. Thanks.
Add a Patch
Add a Pull Request
check this patch out.
I'm not sure if error callback should be still a requirement, though it is in libevent itself.
The point is that we actually always specify C callbacks for libevent, but PHP callbacks can be missing - that won't result in any error.
What do you think?
It works! Excuse me for the late answer and thank you very
much for quick patch.
I'm not sure too, but I always define errorcb. I think that it
should be a requirement, because it's requirement at C-level.