X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=copy.c;h=3ce0f2e7518f72afc621f5faec516846615ca3a7;hp=2b763507e09b0bb7db1ba1cd3aa6513bc4089fac;hb=6b4750772eba54f979455376713b49900a4d5016;hpb=420f3633557ed75a0de989eb065af6e09eed29ba diff --git a/copy.c b/copy.c index 2b76350..3ce0f2e 100644 --- a/copy.c +++ b/copy.c @@ -16,6 +16,10 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA. */ +#if HAVE_CONFIG_H +# include "config.h" +#endif + #include "mutt.h" #include "mailbox.h" #include "mx.h" @@ -375,15 +379,10 @@ mutt_copy_header (FILE *in, HEADER *h, FILE *out, int flags, const char *prefix) if (flags & CH_UPDATE) { if ((flags & CH_NOSTATUS) == 0) -#ifdef IMAP_EDIT_THREADS -#define NEW_ENV new_env -#else -#define NEW_ENV env -#endif { - if (h->irt_changed && h->NEW_ENV->in_reply_to) + if (h->irt_changed && h->new_env->in_reply_to) { - LIST *listp = h->NEW_ENV->in_reply_to; + LIST *listp = h->new_env->in_reply_to; if (fputs ("In-Reply-To: ", out) == EOF) return (-1); @@ -396,9 +395,9 @@ mutt_copy_header (FILE *in, HEADER *h, FILE *out, int flags, const char *prefix) return (-1); } - if (h->refs_changed && h->NEW_ENV->references) + if (h->refs_changed && h->new_env->references) { - LIST *listp = h->NEW_ENV->references, *refs = NULL, *t; + LIST *listp = h->new_env->references, *refs = NULL, *t; if (fputs ("References: ", out) == EOF) return (-1); @@ -423,7 +422,6 @@ mutt_copy_header (FILE *in, HEADER *h, FILE *out, int flags, const char *prefix) if (fputc ('\n', out) == EOF) return (-1); } -#undef NEW_ENV if (h->old || h->read) { @@ -652,6 +650,8 @@ _mutt_copy_message (FILE *fpout, FILE *fpin, HEADER *hdr, BODY *body, s.flags |= M_WEED; if (flags & M_CM_CHARCONV) s.flags |= M_CHARCONV; + if (flags & M_CM_REPLYING) + s.flags |= M_REPLYING; if (WithCrypto && flags & M_CM_VERIFY) s.flags |= M_VERIFY; @@ -972,7 +972,7 @@ static int address_header_decode (char **h) default: return 0; } - if ((a = rfc822_parse_adrlist (a, s + l + 1)) == NULL) + if ((a = rfc822_parse_adrlist (a, s + l)) == NULL) return 0; mutt_addrlist_to_local (a);