continue;
from = 1;
}
+ else if (flags & (CH_NOQFROM) &&
+ ascii_strncasecmp (">From ", buf, 6) == 0)
+ continue;
+
else if (buf[0] == '\n' || (buf[0] == '\r' && buf[1] == '\n'))
break; /* end of header */
CH_UPDATE_LEN write new Content-Length: and Lines:
CH_XMIT ignore Lines: and Content-Length:
CH_WEED do header weeding
+ CH_NOQFROM ignore ">From " line
prefix
string to use if CH_PREFIX is set
#define CH_NOLEN (1<<12) /* don't write Content-Length: and Lines: */
#define CH_WEED_DELIVERED (1<<13) /* weed eventual Delivered-To headers */
#define CH_FORCE_FROM (1<<14) /* give CH_FROM precedence over CH_WEED? */
+#define CH_NOQFROM (1<<15) /* give CH_FROM precedence over CH_WEED? */
/* flags for mutt_enter_string() */
#define M_ALIAS 1 /* do alias "completion" by calling up the alias-menu */
mutt_mktemp (tempfile);
if ((f = safe_fopen (tempfile, "w")) != NULL)
{
- int ch_flags = CH_XMIT | CH_NONEWLINE;
+ int ch_flags = CH_XMIT | CH_NONEWLINE | CH_NOQFROM;
if (!option (OPTBOUNCEDELIVERED))
ch_flags |= CH_WEED_DELIVERED;
fseek (fp, h->offset, 0);
- mutt_copy_header (fp, h, f, ch_flags, NULL);
fprintf (f, "Resent-From: %s", resent_from);
fprintf (f, "\nResent-%s", mutt_make_date (date, sizeof(date)));
fputs ("Resent-To: ", f);
mutt_write_address_list (to, f, 11);
+ mutt_copy_header (fp, h, f, ch_flags, NULL);
fputc ('\n', f);
mutt_copy_bytes (fp, f, h->content->length);
fclose (f);