From: krw Date: Mon, 28 Jul 2014 22:18:31 +0000 (+0000) Subject: Last (known) msgbuf_write() vs EOF fix. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=ffb968af6e63c7f5ef4f42bd05f6c37d59a171fd;p=openbsd Last (known) msgbuf_write() vs EOF fix. ok gilles@ deraadt@ --- diff --git a/usr.sbin/smtpd/enqueue.c b/usr.sbin/smtpd/enqueue.c index 5f04d90a4e5..a6690235980 100644 --- a/usr.sbin/smtpd/enqueue.c +++ b/usr.sbin/smtpd/enqueue.c @@ -1,4 +1,4 @@ -/* $OpenBSD: enqueue.c,v 1.82 2014/07/20 01:38:40 guenther Exp $ */ +/* $OpenBSD: enqueue.c,v 1.83 2014/07/28 22:18:31 krw Exp $ */ /* * Copyright (c) 2005 Henning Brauer @@ -770,7 +770,7 @@ open_connection(void) imsg_compose(ibuf, IMSG_CTL_SMTP_SESSION, IMSG_VERSION, 0, -1, NULL, 0); while (ibuf->w.queued) - if (msgbuf_write(&ibuf->w) < 0 && errno != EAGAIN) + if (msgbuf_write(&ibuf->w) <= 0 && errno != EAGAIN) err(1, "write error"); while (1) {