changeset: 6329:d7d83298011a user: Kevin McCarthy <ke...@8t8.us> date: Fri Apr 26 12:10:46 2013 -0700 link: http://dev.mutt.org/hg/mutt/rev/d7d83298011a
Fix postpone/resume to not remove a Mail-Followup-To header (closes #3070) This solution changes mutt_prepare_template() to check whether the message_id field is NULL to decide whether to wipe the message-id and mail-followup-to headers when instantiating the message. If we are resending a message, we don't want the previous message-id and mail-followup-to headers. If we are resuming a postponed message, however, we want to keep the mail-followup-to header if any was set before the postpone. diffs (21 lines): diff -r 77a852c7840e -r d7d83298011a postpone.c --- a/postpone.c Tue Oct 22 16:24:08 2013 -0500 +++ b/postpone.c Fri Apr 26 12:10:46 2013 -0700 @@ -545,8 +545,15 @@ newhdr->content->length = hdr->content->length; mutt_parse_part (fp, newhdr->content); - FREE (&newhdr->env->message_id); - FREE (&newhdr->env->mail_followup_to); /* really? */ + /* If message_id is set, then we are resending a message and don't want + * message_id or mail_followup_to. Otherwise, we are resuming a + * postponed message, and want to keep the mail_followup_to. + */ + if (newhdr->env->message_id != NULL) + { + FREE (&newhdr->env->message_id); + FREE (&newhdr->env->mail_followup_to); + } /* decrypt pgp/mime encoded messages */