diff options
author | Claudio Jeker <claudio@cvs.openbsd.org> | 2024-11-21 12:48:35 +0000 |
---|---|---|
committer | Claudio Jeker <claudio@cvs.openbsd.org> | 2024-11-21 12:48:35 +0000 |
commit | dd3648fb1a9c18c8d2d8b26fc0c7ff76bffadc9f (patch) | |
tree | c788fdfbd36bd58a5f8b4e9509d2ac5f2251c730 /lib | |
parent | 8b10f68372fd0e881086c4872590652916a3b0d9 (diff) |
imsg_flush() should retry the write on EAGAIN errors.
OK tb@
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libutil/imsg.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libutil/imsg.c b/lib/libutil/imsg.c index bc9bc590f68..e342402747f 100644 --- a/lib/libutil/imsg.c +++ b/lib/libutil/imsg.c @@ -1,4 +1,4 @@ -/* $OpenBSD: imsg.c,v 1.25 2024/11/21 12:48:02 claudio Exp $ */ +/* $OpenBSD: imsg.c,v 1.26 2024/11/21 12:48:34 claudio Exp $ */ /* * Copyright (c) 2023 Claudio Jeker <claudio@openbsd.org> @@ -423,7 +423,7 @@ int imsg_flush(struct imsgbuf *imsgbuf) { while (imsgbuf->w.queued) - if (msgbuf_write(&imsgbuf->w) <= 0) + if (msgbuf_write(&imsgbuf->w) <= 0 && errno != EAGAIN) return (-1); return (0); } |