[Mutt] #3342: mutt should use the Sender: header for evenlope from (for both sendmail and smtp)
#3342: mutt should use the Sender: header for evenlope from (for both sendmail
and
smtp)
--------------------+-------------------------------------------------------
Reporter: Giel | Owner: mutt-dev
Type: defect | Status: new
Priority: major | Milestone:
Component: mutt | Version:
Keywords: |
--------------------+-------------------------------------------------------
When mutt sends an e-mail (with use_envelope_from set in case of sendmail)
it should use the contents of the `Sender:`, when available, before the
`From:` header to construct the sender envelope.
E.g. when a message is given with these headers:
{{{
From: John Doe <jdoe@xxxxxxxxxxxxxxx>
Sender: Michael Jones <mjones@xxxxxxxxxxxxxxx>
...
}}}
This should be used for the envelope (or equivalent `-f` option for
sendmail):
{{{
MAIL FROM:<mjones@xxxxxxxxxxxxxxx>
}}}
Currently, however, the code only looks for the contents of the `From:`
header. Attached patch changes this by making sure the `Sender:` header is
tried first, falling back to `From:` when failing that.
Some people might dislike use of the ternary operator though. Please let
me know if you'd rather see an explicit if-statement.
--
Ticket URL: <http://dev.mutt.org/trac/ticket/3342>
Mutt <http://www.mutt.org/>
The Mutt mail user agent