diff -r 6a8a845df07c -r 0f57e2995a16 imsgev.c --- a/imsgev.c Wed Aug 20 21:46:02 2014 +0500 +++ b/imsgev.c Sat Aug 23 09:19:50 2014 +0500 @@ -138,7 +138,7 @@ * closed, or some error occured. Both case are not recoverable * from the imsg perspective, so we treat it as a WRITE error. */ - if ((n = msgbuf_write(&ibuf->w)) != 1) { + if ((n = msgbuf_write(&ibuf->w)) <= 0 && errno != EAGAIN) { imsgev_disconnect(iev, IMSGEV_EWRITE); return; }