From 04339771ecf9b00234566dadabb370cd2c4bf332 Mon Sep 17 00:00:00 2001 From: henning <> Date: Thu, 11 Aug 2005 16:26:29 +0000 Subject: [PATCH] on writing, we actually can deal with ENOBUFS just as well as with EAGAIN and EINTR, so do it, more or less from bgpd --- src/usr.sbin/ntpd/buffer.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/usr.sbin/ntpd/buffer.c b/src/usr.sbin/ntpd/buffer.c index 173bad3b..63607fe7 100644 --- a/src/usr.sbin/ntpd/buffer.c +++ b/src/usr.sbin/ntpd/buffer.c @@ -1,4 +1,4 @@ -/* $OpenBSD: buffer.c,v 1.8 2005/08/11 16:21:52 henning Exp $ */ +/* $OpenBSD: buffer.c,v 1.9 2005/08/11 16:26:29 henning Exp $ */ /* * Copyright (c) 2003, 2004 Henning Brauer @@ -107,7 +107,8 @@ msgbuf_write(struct msgbuf *msgbuf) } if ((n = writev(msgbuf->fd, iov, i)) == -1) { - if (errno == EAGAIN || errno == EINTR) /* try again later */ + if (errno == EAGAIN || errno == EINTR || + errno == ENOBUFS) /* try again later */ return (0); else return (-1);