From 7c6c66cc3cc40b663fc2ba8573f26a6aa4cb291e Mon Sep 17 00:00:00 2001 From: nicm Date: Sun, 5 Jan 2020 12:51:43 +0000 Subject: Send errors to stdout in control mode so they don't get reordered with other output, reported by George Nachman in GitHub issue 2048. --- cmd-queue.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cmd-queue.c b/cmd-queue.c index 75b5d8f9..59c7a35c 100644 --- a/cmd-queue.c +++ b/cmd-queue.c @@ -551,7 +551,10 @@ cmdq_error(struct cmdq_item *item, const char *fmt, ...) msg = utf8_sanitize(tmp); free(tmp); } - file_error(c, "%s\n", msg); + if (c->flags & CLIENT_CONTROL) + file_print(c, "%s\n", msg); + else + file_error(c, "%s\n", msg); c->retval = 1; } else { *msg = toupper((u_char) *msg); -- cgit v1.2.3