mutt_copy_hdr (fpin, fpout, a->offset, a->offset + a->length,
CH_MIME | CH_NONEWLINE | CH_XMIT, NULL);
- fputs ("Mime-Version: 1.0\n", fpout);
+ fputs ("MIME-Version: 1.0\n", fpout);
mutt_write_mime_header (a->parts, fpout);
fputc ('\n', fpout);
mutt_write_mime_body (a->parts, fpout);
}
/* Add the MIME headers */
- fputs ("Mime-Version: 1.0\n", fp);
+ fputs ("MIME-Version: 1.0\n", fp);
mutt_write_mime_header (attach, fp);
}
if (eightbit && option (OPTUSE8BITMIME))
args = add_option (args, &argslen, &argsmax, "-B8BITMIME");
- if (option (OPTENVFROM) && from && !from->next) {
- args = add_option (args, &argslen, &argsmax, "-f");
- args = add_args (args, &argslen, &argsmax, from);
+ if (option (OPTENVFROM)) {
+ ADDRESS *f = NULL;
+ if (EnvFrom)
+ f = EnvFrom;
+ else if (from && !from->next)
+ f = from;
+ if (f) {
+ args = add_option (args, &argslen, &argsmax, "-f");
+ args = add_args (args, &argslen, &argsmax, f);
+ }
}
if (DsnNotify) {
args = add_option (args, &argslen, &argsmax, "-N");
rewind (tempfp);
while (fgets (sasha, sizeof (sasha), tempfp) != NULL)
lines++;
- fprintf (msg->fp, "Content-Length: %ld\n", (long) ftell (tempfp));
+ fprintf (msg->fp, "Content-Length: " OFF_T_FMT "\n", (long) ftell (tempfp));
fprintf (msg->fp, "Lines: %d\n\n", lines);
/* copy the body and clean up */