diff --git a/postfix/HISTORY b/postfix/HISTORY index 036b06aa7..89ad8b421 100644 --- a/postfix/HISTORY +++ b/postfix/HISTORY @@ -9989,6 +9989,10 @@ Apologies for any names omitted. Dummy VSTREAM read-write routines. Files: util/dummy_read.c, util/dummy_write.c. +20041221 + + Bugfix: further postcat corner cases. + Open problems: Med: implement ${name[?:]value} in main.cf or update the diff --git a/postfix/src/global/mail_version.h b/postfix/src/global/mail_version.h index c8832a4bc..2d30832f7 100644 --- a/postfix/src/global/mail_version.h +++ b/postfix/src/global/mail_version.h @@ -20,7 +20,7 @@ * Patches change the patchlevel and the release date. Snapshots change the * release date only. */ -#define MAIL_RELEASE_DATE "20041220" +#define MAIL_RELEASE_DATE "20041221" #define MAIL_VERSION_NUMBER "2.2" #define VAR_MAIL_VERSION "mail_version" diff --git a/postfix/src/postcat/postcat.c b/postfix/src/postcat/postcat.c index 5de23acbc..20595357a 100644 --- a/postfix/src/postcat/postcat.c +++ b/postfix/src/postcat/postcat.c @@ -136,8 +136,7 @@ static void postcat(VSTREAM *fp, VSTRING *buffer, int flags) vstream_printf("*** ENVELOPE RECORDS %s ***\n", VSTREAM_PATH(fp)); first = 0; } - if (prev_type == REC_TYPE_CONT && in_message && !msg_verbose - && ((flags & PC_FLAG_OFFSET) != 0 || !TEXT_RECORD(rec_type))) + if (prev_type == REC_TYPE_CONT && !TEXT_RECORD(rec_type)) VSTREAM_PUTCHAR('\n'); if (flags & PC_FLAG_OFFSET) vstream_printf("%9lu ", (unsigned long) offset); @@ -149,11 +148,15 @@ static void postcat(VSTREAM *fp, VSTRING *buffer, int flags) asctime(localtime(&time))); break; case REC_TYPE_CONT: /* REC_TYPE_FILT collision */ - if (msg_verbose) + if (!in_message) + vstream_printf("%s: ", rec_type_name(rec_type)); + else if (msg_verbose) vstream_printf("unterminated_text: "); vstream_fwrite(VSTREAM_OUT, STR(buffer), LEN(buffer)); - if (msg_verbose) + if (!in_message || msg_verbose || (flags & PC_FLAG_OFFSET) != 0) { + rec_type = 0; VSTREAM_PUTCHAR('\n'); + } break; case REC_TYPE_NORM: if (msg_verbose)