From: Rafael Sadowski Subject: relayd: log errors before dropping a control connection To: tech@openbsd.org Date: Sun, 2 Aug 2026 21:32:20 +0200 The control dispatcher silently closed the client connection when imsgbuf_write or imsgbuf_get failed. A relayctl user then saw the command break with no hint why, and nothing in the server log if we want to debug it. OK? diff --git a/control.c b/control.c index fb64608..5cff2c8 100644 --- a/control.c +++ b/control.c @@ -250,6 +250,8 @@ control_dispatch_imsg(int fd, short event, void *arg) if (event & EV_WRITE) { if (imsgbuf_write(&c->iev.ibuf) == -1) { + log_debug("%s: imsgbuf_write: %s", __func__, + strerror(errno)); control_close(fd, cs); return; } @@ -257,6 +259,7 @@ control_dispatch_imsg(int fd, short event, void *arg) for (;;) { if ((n = imsgbuf_get(&c->iev.ibuf, &imsg)) == -1) { + log_debug("%s: imsgbuf_get", __func__); control_close(fd, cs); return; }