From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thierry Volpiatto Newsgroups: gmane.emacs.bugs Subject: bug#13321: 24.3.0.50; Gmail error when replying from Gnus to github Date: Fri, 22 Feb 2013 08:33:52 +0100 Organization: Emacs Helm Message-ID: <877gm0iyzj.fsf@gmail.com> References: <87a9surugk.fsf@gmail.com> <87zk0rffsg.fsf@gmail.com> <87mwwqg78u.fsf@gmail.com> <87ip7eg43v.fsf@gmail.com> <87y5g4gp2c.fsf@gmail.com> <87txp5ocvp.fsf@gmail.com> <877gm1r4lv.fsf@gmail.com> <87fw0pihfz.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1361518490 21792 80.91.229.3 (22 Feb 2013 07:34:50 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 22 Feb 2013 07:34:50 +0000 (UTC) Cc: 13321@debbugs.gnu.org To: Katsumi Yamaoka Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Feb 22 08:35:13 2013 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 1U8n9z-0003wK-Oy for geb-bug-gnu-emacs@m.gmane.org; Fri, 22 Feb 2013 08:35:11 +0100 Original-Received: from localhost ([::1]:47938 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U8n9f-00015h-97 for geb-bug-gnu-emacs@m.gmane.org; Fri, 22 Feb 2013 02:34:51 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:38401) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U8n9c-00015I-3A for bug-gnu-emacs@gnu.org; Fri, 22 Feb 2013 02:34:49 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U8n9W-0002yR-Cd for bug-gnu-emacs@gnu.org; Fri, 22 Feb 2013 02:34:47 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:38229) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U8n9W-0002yJ-84 for bug-gnu-emacs@gnu.org; Fri, 22 Feb 2013 02:34:42 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1U8nAo-0004FQ-MK; Fri, 22 Feb 2013 02:36:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Thierry Volpiatto Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org, bugs@gnus.org Resent-Date: Fri, 22 Feb 2013 07:36:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13321 X-GNU-PR-Package: emacs,gnus X-GNU-PR-Keywords: Original-Received: via spool by 13321-submit@debbugs.gnu.org id=B13321.136151852816284 (code B ref 13321); Fri, 22 Feb 2013 07:36:02 +0000 Original-Received: (at 13321) by debbugs.gnu.org; 22 Feb 2013 07:35:28 +0000 Original-Received: from localhost ([127.0.0.1]:43692 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U8nAE-0004EZ-BX for submit@debbugs.gnu.org; Fri, 22 Feb 2013 02:35:27 -0500 Original-Received: from mail-we0-f178.google.com ([74.125.82.178]:39312) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U8nAB-0004ER-1M for 13321@debbugs.gnu.org; Fri, 22 Feb 2013 02:35:25 -0500 Original-Received: by mail-we0-f178.google.com with SMTP id x48so270346wey.37 for <13321@debbugs.gnu.org>; Thu, 21 Feb 2013 23:34:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:to:cc:subject:organization:references:date :in-reply-to:message-id:user-agent:mime-version:content-type; bh=7KDIA8xBOvevW+GLXFsdbmq4C05NcvuSX+VQUVmGvjw=; b=VmWO+BCxp6rMcitaAq2CqVUijtcINvugI/hhmIf693MnElPvtjoMGwN3mnJXGPNtrG pnaNw05DI3CTtM0FLqWcnVrSuTCB1iGpfD3Ncfg+4NCfbst8R7MpHRyHU25jB/InnST8 Rl/RiDyF7PFGBzFh+BsbbCDo/7Beku9q4Qgq6G8AJBAXfzZjdGelv/oCiYXb9ahaERl+ gmyjEk07ldi65Wdu2BpXJ/87i2u6XwW3gSqRlY4pxGaIJTqff8XZdiW7Kna+qOgx8/o/ ualTB9liX7efNzSfjKtiDBYysw7Fm1rL3KUSEUaOIkbRROrUcCY42YdxP8hjZF6GMmkE 9HxQ== X-Received: by 10.180.8.4 with SMTP id n4mr1375858wia.13.1361518441202; Thu, 21 Feb 2013 23:34:01 -0800 (PST) Original-Received: from dell-14z (lbe83-2-78-243-104-167.fbx.proxad.net. [78.243.104.167]) by mx.google.com with ESMTPS id dw1sm1829527wib.5.2013.02.21.23.33.59 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 21 Feb 2013 23:33:59 -0800 (PST) In-Reply-To: (Katsumi Yamaoka's message of "Fri, 22 Feb 2013 16:15:50 +0900") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.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:71627 Archived-At: Hi Katsumi, Katsumi Yamaoka writes: > Thierry Volpiatto wrote: >> Here the commit that introduce this bug: >> 2559724 * >>| Author: Katsumi Yamaoka >>| Date: Mon Nov 19 06:24:03 2012 +0000 >>| >>| message.el (message-get-reply-headers): Make sure the reply goes to the author if it is a wide reply > > This log message suggested that the author (i.e., the From: address) > of a mail didn't appear in a message header when starting composing > a wide reply. I mean, if you perform a wide reply using the `F' or > the `S W' command to a mail like the following: > > From: the-author@example.com.invalid > To: the-mailing-list@example.com.invalid > Cc: foo@example.com.invalid > Reply-To: the-mailing-list@example.com.invalid > > The old one will compose a draft as follows: > > To: the-mailing-list@example.com.invalid > Cc: foo@example.com.invalid > > But the present one does: > > To: the-author@example.com.invalid > Cc: the-mailing-list@example.com.invalid, foo@example.com.invalid > > This is much better for a wide reply, isn't it? The root cause of > this difference is due to the Reply-To header, that some mailing > list servers are likely to add (it may be because many mail clients > compose a draft to send to only the author, I guess). > > Is your problem that the From address is invalid? Yes. > If so, if there is a valid Reply-To header, you can use R rather than > F. Anyway even when hitting "F" this shouldn't happen. > Otherwise, feel free to forward an example mail to me. Will (re)send in next post. Here a patch that fix the problem, please review, I am not familiar with all these mails headers. Note that the second when clause is not needed when setting author before, and don't corrupt further the "to" header when wide is not used. Also my english is not very good, but I don't understand your comments, please fix it (I leave long lines to see better). Thanks. diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index 808e1ed..8b9df3c 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el @@ -6720,17 +6720,17 @@ The function is called with one parameter, a cons cell ..." ", ")) mct (message-fetch-field "mail-copies-to") author (or (message-fetch-field "mail-reply-to") - (message-fetch-field "reply-to")) + (message-fetch-field "reply-to") + (message-fetch-field "from") + "") mft (and message-use-mail-followup-to (message-fetch-field "mail-followup-to"))) ;; Make sure this message goes to the author if this is a wide - ;; reply, since Reply-To address may be a list address a mailing - ;; list server added. + ;; reply, FIXME: please fix the commented line following, it seem the second one is good and the first one wrong. + ;; since Reply-To address may be a list address a mailing list server added. + ;; since Reply-to adress may be a mailing list address with server added. (when (and wide author) - (setq cc (concat author ", " cc))) - (when (or wide (not author)) - (setq author (or (message-fetch-field "from") "")))) - + (setq cc (concat author ", " cc)))) ;; Handle special values of Mail-Copies-To. (when mct (cond ((or (equal (downcase mct) "never") -- Thierry Get my Gnupg key: gpg --keyserver pgp.mit.edu --recv-keys 59F29997