From 05065d99c78a53f6ab97086574a01d75be79decc Mon Sep 17 00:00:00 2001 From: Pav Lucistnik Date: Mon, 18 Jul 2005 16:04:16 +0000 Subject: - Patch nine bugs: #79 - INTERNALDATE reponses do not conform to RFC #145 - LMTP loses return-path #177 - Compile Fails on FreeBSD (fixes compilation on FreeBSD 4.X) #184 - socklen_t issue #190 - huge load if database crash #198 - DBMail processes killing each other #199 - spare child creates zombie #214 - dbmail-smtp dumps core with double free #216 - malformed header prevents delivery - Fix RC_SUBR usage PR: ports/83437, also ports/80736, ports/82437, ports/83575 Submitted by: Mark Starovoytov , parts also by: Radim Kolar , thompsa, Marcus Grando Approved by: maintainer timeout (2 months on oldest PR) --- mail/dbmail/files/patch-2.0.4_bug216_header.c | 37 +++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 mail/dbmail/files/patch-2.0.4_bug216_header.c (limited to 'mail/dbmail/files/patch-2.0.4_bug216_header.c') diff --git a/mail/dbmail/files/patch-2.0.4_bug216_header.c b/mail/dbmail/files/patch-2.0.4_bug216_header.c new file mode 100644 index 000000000000..d9610a5cd609 --- /dev/null +++ b/mail/dbmail/files/patch-2.0.4_bug216_header.c @@ -0,0 +1,37 @@ +Index: header.c +=================================================================== +--- header.c (revision 1796) ++++ header.c (revision 1813) +@@ -176,15 +176,17 @@ + if (message_content[line_content_size] == '\n') { + tmp_line_size = line_content_size + 1; + tmp_line_rfcsize = tmp_line_size + 1; +- } else { +- if (message_content[line_content_size] == '\r' && +- message_content[line_content_size + 1] == '\n') { ++ } else if (message_content[line_content_size] == '\r') { ++ if (message_content[line_content_size + 1] == '\n') { ++ /* This is the right behaviour */ + tmp_line_size = line_content_size + 2; + tmp_line_rfcsize = tmp_line_size; + } else { +- trace(TRACE_ERROR, "%s,%s: error reading header line", +- __FILE__, __func__); +- return -1; ++ /* This is broken behaviour, but it's better ++ * than not handling it at all. ++ */ ++ tmp_line_size = line_content_size + 1; ++ tmp_line_rfcsize = tmp_line_size + 1; + } + } + } +@@ -197,7 +199,6 @@ + __FILE__, __func__); + return 0; + } +- else +- return 1; ++ return 1; + + } -- cgit v1.2.3