Hi Philippe!

On Thu, 10 Jan 2013 14:05:43 +0100, Philippe Naudin wrote:
> A cron job output some warning with accented characters. This warning
> is a single line :
> Serveur présent jouy.inra.fr = 138.102.1.1, mais client pas à l'heure
> (it warns about a NTP server completely desynchronized).
> 
> This warning is sent by msmtp (sendmail is a symlink to msmtp) to a
> SMTP server (postfix).
> 
> In the message, there is a header :
> Content-Type: text/plain; charset=ANSI_X3.4-1968
> 
> I would like to get :
> Content-Type: text/plain; charset=ISO-8859-1
> 
> Is there a way to force the default charset with msmtp ?

Msmtp does not inspect or alter mail contents; it just forwards them to
the SMTP server. So what you pipe into msmtp has to be in valid mail
format, including Content-Type and other headers.

You could add that header yourself, e.g. using a small intermediate
script between cron and msmtp. Or you could configure postfix to
assume a different default charset if none is specified.

Martin



------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:
http://p.sf.net/sfu/learnmore_122712
_______________________________________________
msmtp-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/msmtp-users

Reply via email to