Skip to content
Snippets Groups Projects
Commit 9b4ab9fe authored by Vladimir Davydov's avatar Vladimir Davydov Committed by Vladimir Davydov
Browse files

iproto: use iostream abstraction

Instead of writing to the socket fd directly using sio, we wrap it in
iostream. This will allow us to use complex communication protocols in
iproto.

One thing that should be noted about this patch is how we handle
ev_io_start when we need to wait for the socket to become readable or
writable. Since iostream_write can block because it wants to read from
the socket and iostream_read can block because it wants to write to the
socket, we might need to update input/output events before ev_io_start.
Since ev_io events can't be updated while ev_io is active, we need to
stop ev_io for this.
parent 91166ca8
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment