introduce io_eagain_read and io_eagain_write (discontinue using io_eagain plz)

This commit is contained in:
leitner
2014-06-05 20:43:01 +00:00
parent d9cbb3940c
commit 39e7ee90bb
6 changed files with 40 additions and 7 deletions

View File

@@ -235,7 +235,7 @@ int main() {
buffer_putnlflush(buffer_2);
}
if (errno==EAGAIN)
io_eagain(s);
io_eagain_read(s);
else
carp("socket_accept6");
} else {
@@ -285,7 +285,7 @@ emerge:
struct http_data* h=io_getcookie(i);
int64 r=iob_send(i,&h->iob);
/* printf("iob_send returned %lld\n",r); */
if (r==-1) io_eagain(i); else
if (r==-1) io_eagain_write(i); else
if (r<=0) {
array_trunc(&h->r);
iob_reset(&h->iob);