shaman icon indicating copy to clipboard operation
shaman copied to clipboard

async/event interface

Open buhman opened this issue 9 years ago • 1 comments

http://curl.haxx.se/libcurl/c/libcurl-multi.html

In particular I'm interested in

Enable the application to wait for action on its own file descriptors and curl's file descriptors simultaneous easily.

Roughly, you should be writing your HTTP request to the socket, then passing the socket back to me (the libshaman caller). I then use that in my own epoll loop, then give you back your descriptor to do the real read, and give me the data I asked for.

Ultimately, it would allow things like prc to handle other irc-protocol things without waiting for OWM to do the hokey-pokey.

Let me know if you want this, and I'll get started on a PR.

buhman avatar Jul 26 '14 23:07 buhman