From 0461562f6326dfff4c6eedb18a5b831eb8475efe Mon Sep 17 00:00:00 2001 From: Matthias Andree Date: Wed, 28 Oct 2009 16:24:23 +0000 Subject: Regression fix for multiline SMTP bugfix. Reported by Thomas Jarosch. svn path=/branches/BRANCH_6-3/; revision=5445 --- smtp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'smtp.c') diff --git a/smtp.c b/smtp.c index e6047f8f..ef6cdb2d 100644 --- a/smtp.c +++ b/smtp.c @@ -352,16 +352,16 @@ int SMTP_ok(int sock, char smtp_mode, int mintimeout) last_smtp_ok = time((time_t *) NULL); + strlcat(smtp_response, reply, sizeof(smtp_response)); + if (strchr("123", reply[0]) && isdigit((unsigned char)reply[1]) && isdigit((unsigned char)reply[2]) && strchr(" ", reply[3])) /* matches space and \0 */ { - strlcat(smtp_response, reply, sizeof(smtp_response)); return SM_OK; } else if (reply[3] != '-') return SM_ERROR; - strlcat(smtp_response, reply, sizeof(smtp_response)); strlcat(smtp_response, "\r\n", sizeof(smtp_response)); /* set an alarm for smtp ok */ -- cgit v1.2.3