#605767 git-email: UTF-8 content in To: causes Subject: to also be RFC2047 encoded

#605767#5
Date:
2010-12-03 10:00:22 UTC
From:
To:
If To: contains a non-ASCII character, the Subject: header is RFC2047
encoded even if it contains only ASCII characters:

=== Begin ===
From: Sascha Silbe <sascha-pgp@silbe.org>
To: =?UTF-8?q?St=C3=A9phane=20Magnenat?= <stephane.magnenat@mavt.ethz.ch>
Subject: =?UTF-8?q?Patches=20for=20Osqoop?=
Date: Fri,  3 Dec 2010 10:51:30 +0100
Message-Id: <1291369892-17749-1-git-send-email-sascha-pgp@silbe.org>
X-Mailer: git-send-email 1.7.2.3
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
=== End ===


I haven't checked what happens for different header combinations (e.g.
Subject: or From: containing non-ASCII and To: only ASCII), but would
expect them to show the same issue.

#605767#10
Date:
2010-12-03 10:20:37 UTC
From:
To:
Hi Sascha,

Sascha Silbe wrote:

 $ git format-patch HEAD^..HEAD;	# some plain ASCII patch
 $ git send-email --to='Jönäthän Nïëdër <jrnieder@gmail.com>' 0001*
 Who should the emails appear to be from? [Jonathan Nieder <jrnieder@gmail.com>]
 Emails will be sent from: Jonathan Nieder <jrnieder@gmail.com>
 Message-ID to be used as In-Reply-To for the first email?
 (mbox) Adding cc: Jonathan Nieder <jrnieder@gmail.com> from line 'From: Jonathan Nieder <jrnieder@gmail.com>'

 From: Jonathan Nieder <jrnieder@gmail.com>
 To: =?UTF-8?q?J=C3=B6n=C3=A4th=C3=A4n=20N=C3=AF=C3=ABd=C3=ABr?= <jrnieder@gmail.com>
 Cc: Jonathan Nieder <jrnieder@gmail.com>
 Subject: [PATCH] work around inability of patches to represent new directories
 Date: Fri,  3 Dec 2010 04:15:25 -0600
 Message-Id: <1291371325-12369-1-git-send-email-jrnieder@gmail.com>
 X-Mailer: git-send-email 1.7.2.4

     The Cc list above has been expanded by additional
     addresses found in the patch commit message. By default
     send-email prompts before sending whenever this occurs.
     This behavior is controlled by the sendemail.confirm
     configuration setting.

     For additional information, run 'git send-email --help'.
     To retain the current behavior, but squelch this message,
     run 'git config --global sendemail.confirm auto'.

 Send this email? ([y]es|[n]o|[q]uit|[a]ll): q

The subject seems to be ASCII.  Ideas?

#605767#15
Date:
2010-12-03 11:43:34 UTC
From:
To:
Excerpts from Jonathan Nieder's message of Fri Dec 03 11:20:37 +0100 2010:

Hmm, maybe the fact that it asked for the encoding (because the cover
letter contained the recipients real name in the body) played a role.
Shame on me for not posting the entire output which might have suggested
this.

Sascha