26 lines
990 B
Diff
26 lines
990 B
Diff
From 73937b5fe7eb1dde76f30ef6b181c920bbbc4558 Mon Sep 17 00:00:00 2001
|
|
From: Timo Sirainen <timo.sirainen@open-xchange.com>
|
|
Date: Mon, 24 Aug 2020 16:58:16 +0300
|
|
Subject: [PATCH] imap: Fix crash if imap-hibernate socket can't be connected
|
|
to
|
|
|
|
The error was supposed to be returned to caller, not logged directly.
|
|
---
|
|
src/imap/imap-client-hibernate.c | 3 ++-
|
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/src/imap/imap-client-hibernate.c b/src/imap/imap-client-hibernate.c
|
|
index 4ef323453c..d3451b1bf6 100644
|
|
--- a/src/imap/imap-client-hibernate.c
|
|
+++ b/src/imap/imap-client-hibernate.c
|
|
@@ -176,7 +176,8 @@ imap_hibernate_process_send(struct client *client, const buffer_t *state,
|
|
"/"IMAP_HIBERNATE_SOCKET_NAME, NULL);
|
|
fd = net_connect_unix_with_retries(path, 1000);
|
|
if (fd == -1) {
|
|
- i_error("net_connect_unix(%s) failed: %m", path);
|
|
+ *error_r = t_strdup_printf(
|
|
+ "net_connect_unix(%s) failed: %m", path);
|
|
return -1;
|
|
}
|
|
net_set_nonblock(fd, FALSE);
|