git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Krzysztof Mazur <krzysiek@podlesie.net>
To: peff@peff.net
Cc: gitster@pobox.com, git@vger.kernel.org,
	Krzysztof Mazur <krzysiek@podlesie.net>
Subject: [PATCH] git-send-email: add rfc2047 quoting for "=?"
Date: Wed, 24 Oct 2012 23:28:29 +0200	[thread overview]
Message-ID: <1351114109-16310-1-git-send-email-krzysiek@podlesie.net> (raw)
In-Reply-To: <20121024210826.GA23562@shrek.podlesie.net>

For raw subjects rfc2047 quoting is needed not only for non-ASCII characters,
but also for any possible rfc2047 in it.

Signed-off-by: Krzysztof Mazur <krzysiek@podlesie.net>
---
Oops, this ugly Subject was generated by git format-patch (both 1.8.0
and km/send-email-compose-encoding).

 git-send-email.perl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/git-send-email.perl b/git-send-email.perl
index eb1b876..cfd20fa 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -908,7 +908,7 @@ sub is_rfc2047_quoted {
 sub subject_needs_rfc2047_quoting {
 	my $s = shift;
 
-	return ($s =~ /[^[:ascii:]]/);
+	return ($s =~ /[^[:ascii:]]/) || ($s =~ /=\?/);
 }
 
 sub quote_subject {
-- 
1.8.0.rc0.30.g72615bf

  reply	other threads:[~2012-10-24 21:29 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-24  8:03 [PATCH] git-send-email: skip RFC2047 quoting for ASCII subjects Krzysztof Mazur
2012-10-24  8:46 ` Jeff King
2012-10-24 17:10   ` Krzysztof Mazur
2012-10-24 19:25     ` Jeff King
2012-10-24 21:08       ` Krzysztof Mazur
2012-10-24 21:28         ` Krzysztof Mazur [this message]
2012-10-25  9:05           ` [PATCH] git-send-email: add rfc2047 quoting for "=?" Jeff King
2012-10-25  9:01         ` [PATCH] git-send-email: skip RFC2047 quoting for ASCII subjects Jeff King
2012-10-25 10:08           ` Jeff King
2012-10-25 11:19             ` Krzysztof Mazur
2012-10-25 11:21               ` Jeff King
2012-10-25 11:12           ` Krzysztof Mazur

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1351114109-16310-1-git-send-email-krzysiek@podlesie.net \
    --to=krzysiek@podlesie.net \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).