]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-lda: smtp client may have crashed if remote returned a permanent error.
authorTimo Sirainen <tss@iki.fi>
Fri, 3 Oct 2014 19:39:53 +0000 (22:39 +0300)
committerTimo Sirainen <tss@iki.fi>
Fri, 3 Oct 2014 19:39:53 +0000 (22:39 +0300)
src/lib-lda/smtp-client.c

index ca503eb4cf2ef9eb21fdb0132637ce515cd78761..08be256b8dd033aee56f742d23de39eacbd55a0f 100644 (file)
@@ -317,8 +317,11 @@ smtp_client_send_flush(struct smtp_client *smtp_client, const char **error_r)
                i_assert(smtp_client->error != NULL);
                *error_r = t_strdup(smtp_client->error);
                return -1;
-       } else
+       } else {
+               i_assert(smtp_client->error != NULL);
+               *error_r = t_strdup(smtp_client->error);
                return 0;
+       }
 }
 
 int smtp_client_deinit(struct smtp_client *client, const char **error_r)