From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nicolas Graner Newsgroups: gmane.emacs.bugs Subject: bug#20396: 24.5; incorrect subject in replies Date: Mon, 27 Apr 2015 22:45:44 +0200 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1430168557 28897 80.91.229.3 (27 Apr 2015 21:02:37 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 27 Apr 2015 21:02:37 +0000 (UTC) Cc: 20396@debbugs.gnu.org To: Glenn Morris Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Apr 27 23:02:26 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YmqAb-0004HE-Tc for geb-bug-gnu-emacs@m.gmane.org; Mon, 27 Apr 2015 23:02:26 +0200 Original-Received: from localhost ([::1]:57618 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmqAb-0001KY-6C for geb-bug-gnu-emacs@m.gmane.org; Mon, 27 Apr 2015 17:02:25 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48762) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmqAR-0008W5-9A for bug-gnu-emacs@gnu.org; Mon, 27 Apr 2015 17:02:20 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ympuo-0007Sl-33 for bug-gnu-emacs@gnu.org; Mon, 27 Apr 2015 16:46:07 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:51830) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ympun-0007SZ-Vo for bug-gnu-emacs@gnu.org; Mon, 27 Apr 2015 16:46:06 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Ympum-0001Oa-Ms for bug-gnu-emacs@gnu.org; Mon, 27 Apr 2015 16:46:04 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Nicolas Graner Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 27 Apr 2015 20:46:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 20396 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 20396-submit@debbugs.gnu.org id=B20396.14301675615350 (code B ref 20396); Mon, 27 Apr 2015 20:46:04 +0000 Original-Received: (at 20396) by debbugs.gnu.org; 27 Apr 2015 20:46:01 +0000 Original-Received: from localhost ([127.0.0.1]:41606 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Ympuh-0001OD-OJ for submit@debbugs.gnu.org; Mon, 27 Apr 2015 16:46:00 -0400 Original-Received: from panel.vitry.ouvaton.coop ([194.36.166.20]:60470) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Ympuf-0001O3-AB for 20396@debbugs.gnu.org; Mon, 27 Apr 2015 16:45:58 -0400 Original-Received: from packard-a156abe (110.124.67.86.rev.sfr.net [86.67.124.110]) by panel.vitry.ouvaton.coop (Postfix) with ESMTPSA id C3F9FA2287; Mon, 27 Apr 2015 22:45:55 +0200 (CEST) In-Reply-To: (message from Glenn Morris on Mon, 27 Apr 2015 15:30:18 -0400) X-PPP-Message-ID: <20150427204556.26235.95364@panel.vitry.ouvaton.coop> X-PPP-Vhost: graner.name X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:102114 Archived-At: Glenn Morris wrote: > Nicolas Graner wrote: > >> When you reply to a message whose Subject starts with "Re: ", this is >> normally stripped from the Subject before a new "Re: " is added in the >> reply. But if the Subject is RFC2047-encoded, stripping does not >> happen and you end up with "Re: Re: " in the reply. > > Thanks for the report. Does this fix it? > (Apply patch, M-x emacs-lisp-byte-compile-and-load rmail.el) Yes, it works. Thanks! Nicolas > --- a/lisp/mail/rmail.el > +++ b/lisp/mail/rmail.el > @@ -3830,7 +3830,8 @@ use \\[mail-yank-original] to yank the original message into it." > ;;; (setq cc resent-cc))) > ;; Add `Re: ' to subject if not there already. > (and (stringp subject) > - (setq subject > + (setq subject (rfc2047-decode-string subject) > + subject > (concat rmail-reply-prefix > (if (let ((case-fold-search t)) > (string-match rmail-reply-regexp subject))