Subject: bug#25436: 25.1; sendmail does not add a Date: header in FCC

From: Eli Zaretskii <[email-masked]>
Date: Fri, 13 Jan 2017 17:30:58 +0200

> Date: Fri, 13 Jan 2017 15:41:07 +0100
> From: Francesco Potortì <[email-masked]>
> Cc: [email-masked]
> 
> $ emacs -Q
> M-: (setq mail-user-agent 'sendmail-user-agent)
> C-xm
> add a recipient, subject and text at will
> C-cC-fC-f
> specify an FCC file at will
> C-cC-c
> transport RET
> 
> Now if I look at the FCC file, I see that the sent mail does not contain
> a Date: header.

I did the above, and I do see the "Date" header.  However, I needed a
few additional settings before I could proceed after "C-c C-c".  Here
are the variables I needed to set:

  user-full-name
  user-mail-address
  smtpmail-smtp-server
  smtpmail-smtp-service
  smtpmail-stream-type

Not sure if any of the above is relevant to the issue at hand.

Can you step through sendmail-send-it, and see what happens there with
the date header?  According to my reading of the code, by the time
mail-do-fcc is invoked, the Date header is supposed to be already in
the mail buffer, and that buffer is inserted verbatim into FCC.