[dovecot-cvs] dovecot/src/lib-storage/index/mbox mbox-sync-parse.c, 1.49.2.1, 1.49.2.2

cras at dovecot.org cras at dovecot.org
Sat Jun 17 20:11:31 EEST 2006


Update of /var/lib/cvs/dovecot/src/lib-storage/index/mbox
In directory talvi:/tmp/cvs-serv28504/lib-storage/index/mbox

Modified Files:
      Tag: branch_1_0
	mbox-sync-parse.c 
Log Message:
If mbox headers have CRLF linefeeds, handle them properly instead of
corrupting the headers.



Index: mbox-sync-parse.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/mbox/mbox-sync-parse.c,v
retrieving revision 1.49.2.1
retrieving revision 1.49.2.2
diff -u -d -r1.49.2.1 -r1.49.2.2
--- mbox-sync-parse.c	12 May 2006 13:26:32 -0000	1.49.2.1
+++ mbox-sync-parse.c	17 Jun 2006 17:11:29 -0000	1.49.2.2
@@ -510,8 +510,11 @@
 			buffer_append(ctx->header, hdr->value,
 				      hdr->value_len);
 		}
-		if (!hdr->no_newline)
+		if (!hdr->no_newline) {
+			if (hdr->crlf_newline)
+				str_append_c(ctx->header, '\r');
 			str_append_c(ctx->header, '\n');
+		}
 	}
 	i_assert(ret != 0);
 	message_parse_header_deinit(&hdr_ctx);



More information about the dovecot-cvs mailing list