summaryrefslogtreecommitdiffstats
path: root/usr.sbin/dvmrpctl
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2013-11-14 20:48:51 +0000
committerderaadt <deraadt@openbsd.org>2013-11-14 20:48:51 +0000
commit397afdbc21cd87ee8b77f78a6625971eb021723f (patch)
tree9c4e11447329fe88ad34105d4bbf11b87abf0b0c /usr.sbin/dvmrpctl
parentUse (N * sizeof(struct klist)) instead of (N * sizeof(struct klist *)) (diff)
downloadwireguard-openbsd-397afdbc21cd87ee8b77f78a6625971eb021723f.tar.xz
wireguard-openbsd-397afdbc21cd87ee8b77f78a6625971eb021723f.zip
cope with the EAGAIN API change for msgbuf_write()
ok benno
Diffstat (limited to 'usr.sbin/dvmrpctl')
-rw-r--r--usr.sbin/dvmrpctl/dvmrpctl.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/dvmrpctl/dvmrpctl.c b/usr.sbin/dvmrpctl/dvmrpctl.c
index 1fba47be384..6b3c90e3f94 100644
--- a/usr.sbin/dvmrpctl/dvmrpctl.c
+++ b/usr.sbin/dvmrpctl/dvmrpctl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dvmrpctl.c,v 1.10 2013/04/09 14:51:33 gilles Exp $ */
+/* $OpenBSD: dvmrpctl.c,v 1.11 2013/11/14 20:48:51 deraadt Exp $ */
/*
* Copyright (c) 2005 Claudio Jeker <claudio@openbsd.org>
@@ -28,6 +28,7 @@
#include <net/if_types.h>
#include <err.h>
+#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -172,7 +173,7 @@ main(int argc, char *argv[])
}
while (ibuf->w.queued)
- if (msgbuf_write(&ibuf->w) < 0)
+ if (msgbuf_write(&ibuf->w) <= 0 && errno != EAGAIN)
err(1, "write error");
while (!done) {