Re: [PATCH 1/2] cli: also use Delivered-To header to figure out the reply from address
authorMichael Hudson-Doyle <michael.hudson@canonical.com>
Mon, 14 May 2012 02:15:07 +0000 (14:15 +1200)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:47:05 +0000 (09:47 -0800)
ae/dbcae794c2a15d03d529cb10a311b0cd2fcc87 [new file with mode: 0644]

diff --git a/ae/dbcae794c2a15d03d529cb10a311b0cd2fcc87 b/ae/dbcae794c2a15d03d529cb10a311b0cd2fcc87
new file mode 100644 (file)
index 0000000..5bae87f
--- /dev/null
@@ -0,0 +1,75 @@
+Return-Path: <michael.hudson@canonical.com>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 22123431FBC\r
+       for <notmuch@notmuchmail.org>; Sun, 13 May 2012 19:15:15 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.7\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
+       tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id jhKS3igXtoy7 for <notmuch@notmuchmail.org>;\r
+       Sun, 13 May 2012 19:15:14 -0700 (PDT)\r
+Received: from youngberry.canonical.com (youngberry.canonical.com\r
+       [91.189.89.112])\r
+       by olra.theworths.org (Postfix) with ESMTP id 55EFA431FAE\r
+       for <notmuch@notmuchmail.org>; Sun, 13 May 2012 19:15:14 -0700 (PDT)\r
+Received: from [120.136.5.22] (helo=narsil)\r
+       by youngberry.canonical.com with esmtpsa\r
+       (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71)\r
+       (envelope-from <michael.hudson@canonical.com>)\r
+       id 1STkoa-0006G7-48; Mon, 14 May 2012 02:15:12 +0000\r
+Received: by narsil (Postfix, from userid 1000)\r
+       id C1CCD520111; Mon, 14 May 2012 14:15:07 +1200 (NZST)\r
+From: Michael Hudson-Doyle <michael.hudson@canonical.com>\r
+To: Jani Nikula <jani@nikula.org>, notmuch@notmuchmail.org\r
+Subject: Re: [PATCH 1/2] cli: also use Delivered-To header to figure out the\r
+       reply from address\r
+In-Reply-To:\r
+ <21a946917c5c8dd63295b7c87b7c2d1ebcb6e71e.1336746160.git.jani@nikula.org>\r
+References:\r
+ <21a946917c5c8dd63295b7c87b7c2d1ebcb6e71e.1336746160.git.jani@nikula.org>\r
+User-Agent: Notmuch/0.13~rc1+2~g4ba3aed (http://notmuchmail.org) Emacs/23.3.1\r
+       (x86_64-pc-linux-gnu)\r
+Date: Mon, 14 May 2012 14:15:07 +1200\r
+Message-ID: <8762bz5x04.fsf@canonical.com>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=us-ascii\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Mon, 14 May 2012 02:15:15 -0000\r
+\r
+Jani Nikula <jani@nikula.org> writes:\r
+\r
+> Add another fallback header Delivered-To for guessing the user's from\r
+> address for notmuch reply before using the Received\r
+> headers. Apparently some MTAs use Delivered-To instead of\r
+> X-Original-To (which already exists as a fallback).\r
+>\r
+> Reported-by: Michael Hudson-Doyle <michael.hudson@canonical.com>\r
+> Signed-off-by: Jani Nikula <jani@nikula.org>\r
+\r
+Firstly, thank you so much for doing this!\r
+\r
+Unfortunately it doesn't work for me :( Poking around a bit reveals why:\r
+I have two Delivered-To: headers in the problem mails, and only the\r
+lower/earlier one containst the email address I want to be used as\r
+From:.  And it seems that the only header one can get all values for is\r
+Received...\r
+\r
+Cheers,\r
+mwh\r