diff options
author | Sebastian Benoit <benno@cvs.openbsd.org> | 2013-11-13 20:45:51 +0000 |
---|---|---|
committer | Sebastian Benoit <benno@cvs.openbsd.org> | 2013-11-13 20:45:51 +0000 |
commit | bf115fdb84969e60486ff91130ef6a8c4a592152 (patch) | |
tree | c09c1d4feb2df306ba4e268cd51a8e97490a4512 | |
parent | 6852f0460e4e5e60592fb13fb81dbb98f66ec720 (diff) |
handle msgbuf_write() returning EAGAIN
-rw-r--r-- | usr.sbin/relayd/control.c | 4 | ||||
-rw-r--r-- | usr.sbin/relayd/proc.c | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/relayd/control.c b/usr.sbin/relayd/control.c index e3046f1a7e6..b5be0ca6b7e 100644 --- a/usr.sbin/relayd/control.c +++ b/usr.sbin/relayd/control.c @@ -1,4 +1,4 @@ -/* $OpenBSD: control.c,v 1.44 2013/03/11 17:40:11 deraadt Exp $ */ +/* $OpenBSD: control.c,v 1.45 2013/11/13 20:45:50 benno Exp $ */ /* * Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org> @@ -246,7 +246,7 @@ control_dispatch_imsg(int fd, short event, void *arg) } if (event & EV_WRITE) { - if (msgbuf_write(&c->iev.ibuf.w) < 0) { + if (msgbuf_write(&c->iev.ibuf.w) < 0 && errno != EAGAIN) { control_close(fd, cs); return; } diff --git a/usr.sbin/relayd/proc.c b/usr.sbin/relayd/proc.c index 60d8e87e0da..51ed973fb5e 100644 --- a/usr.sbin/relayd/proc.c +++ b/usr.sbin/relayd/proc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: proc.c,v 1.5 2013/01/17 20:34:18 bluhm Exp $ */ +/* $OpenBSD: proc.c,v 1.6 2013/11/13 20:45:50 benno Exp $ */ /* * Copyright (c) 2010,2011 Reyk Floeter <reyk@openbsd.org> @@ -432,7 +432,7 @@ proc_dispatch(int fd, short event, void *arg) } if (event & EV_WRITE) { - if (msgbuf_write(&ibuf->w) == -1) + if (msgbuf_write(&ibuf->w) == -1 && errno != EAGAIN) fatal(title); } |