Browsing through the source code to find some properties of deliver I stuck here: --- dovecot-1.2.rc3/src/lib-mail/message-header-parser.c.orig 2009-01-07 19:33:26.000000000 +0100 +++ dovecot-1.2.rc3/src/lib-mail/message-header-parser.c 2009-04-23 09:53:08.000000000 +0200 @@ -284,7 +284,7 @@ Exception to this is if the value consists only of LWSP, then skip only the one LWSP after ':'. */ for (pos = 0; pos < line->value_len; pos++) { - if (!IS_LWSP(line->value[0])) + if (!IS_LWSP(line->value[pos])) break; } I'm not clear if this was really indented but the for-loop does not use the variable pos in the loop body. The expression !IS_LWSP(line->value[0]) is invariant and always false if the first character after ':' is a white space, forcing the loop to go through the whole value. This happens only if flag MESSAGE_HEADER_PARSER_FLAG_SKIP_INITIAL_LWSP is active. I saw this in 1.1.4 too. Johann Klasek -- Johann E. Klasek Zentraler Informatikdienst - Kommunikation Technische Universit?t Wien Tel: +43 1 58801-42049 A-1040 Wien, Wiedner Hauptstr. 8-10/020C Fax: +43 1 58801-42099 http://pgpkeys.tuwien.ac.at/ PGP Key jklasek
On Thu, 2009-04-23 at 10:29 +0200, Johann Klasek wrote:> --- dovecot-1.2.rc3/src/lib-mail/message-header-parser.c.orig 2009-01-07 19:33:26.000000000 +0100 > +++ dovecot-1.2.rc3/src/lib-mail/message-header-parser.c 2009-04-23 09:53:08.000000000 +0200 > @@ -284,7 +284,7 @@ > Exception to this is if the value consists only of > LWSP, then skip only the one LWSP after ':'. */ > for (pos = 0; pos < line->value_len; pos++) { > - if (!IS_LWSP(line->value[0])) > + if (!IS_LWSP(line->value[pos])) > break; > }Thanks, committed: http://hg.dovecot.org/dovecot-1.2/rev/c8de2237478f -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 197 bytes Desc: This is a digitally signed message part URL: <http://dovecot.org/pipermail/dovecot/attachments/20090423/26624b90/attachment-0002.bin>
Maybe Matching Threads
- (message_parse_header_next): assertion failed:, +(IS_LWSP(line->value[0])) 1.1beta14
- Possible header parsing problem
- dovecot-2.22.33.2, segfault on empty emails
- X100P panic
- v2.2.27 Panic: file rfc822-parser.h: line 23 (rfc822_parser_deinit): assertion failed: (ctx->data <= ctx->end)