--- /dev/null
+Return-Path: <keevan@fastmail.fm>\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 A8E90431FAF\r
+ for <notmuch@notmuchmail.org>; Sat, 7 Sep 2013 10:08:12 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.799\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.799 tagged_above=-999 required=5\r
+ tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
+ FREEMAIL_FROM=0.001, 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 iKDMdIkjOTf9 for <notmuch@notmuchmail.org>;\r
+ Sat, 7 Sep 2013 10:08:08 -0700 (PDT)\r
+Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com\r
+ [66.111.4.27])\r
+ (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))\r
+ (No client certificate requested)\r
+ by olra.theworths.org (Postfix) with ESMTPS id 46A89431FAE\r
+ for <notmuch@notmuchmail.org>; Sat, 7 Sep 2013 10:08:08 -0700 (PDT)\r
+Received: from compute6.internal (compute6.nyi.mail.srv.osa [10.202.2.46])\r
+ by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id 33C92207A6;\r
+ Sat, 7 Sep 2013 13:08:00 -0400 (EDT)\r
+Received: from frontend1 ([10.202.2.160])\r
+ by compute6.internal (MEProxy); Sat, 07 Sep 2013 13:08:00 -0400\r
+DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=8t8.us; h=date\r
+ :from:to:cc:subject:message-id:references:mime-version\r
+ :content-type:in-reply-to; s=mesmtp; bh=IbZhmQNNUTQ5qeWtDbCt2OXs\r
+ us4=; b=cWmThUHOyWl4/zEpsda6ukfQYTSz2Y+ghivoev4Pi6A8MHKAlsKXbM+p\r
+ XMDvXCvxYjrUAloEkwuLoBtnuQqWFJ143KptVl/fyXrH4sEBuW5BV7zP4EjHytO6\r
+ gC8/jVQsntsAZaObqeR8iD2k0jkNvVyuTRv9ERu6A0EzokltK/Y=\r
+DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=\r
+ messagingengine.com; h=date:from:to:cc:subject:message-id\r
+ :references:mime-version:content-type:in-reply-to; s=smtpout;\r
+ bh=IbZhmQNNUTQ5qeWtDbCt2OXsus4=; b=AE92wIEu2FtpmSUwGjY9WijtKu3q\r
+ 7eeCGVopJ7jYrJ9IcDmqwDXQNGTJTKBtvyPdHeIIDuerKBjeWdi5b3pFTNi6TkeD\r
+ ldI0mG4+sWyQ37s/AEvjs0J5emLjqIJ+ItnVa5cwlzmkeTc1T7czEvKKIgBij139\r
+ 8AxEkLzrzF9r4JE=\r
+X-Sasl-enc: FdJBzkkGbeNA5km8mjpwnw/kKFOkW8gpy3KfGU7uUcq4 1378573679\r
+Received: from localhost (unknown [97.125.94.9])\r
+ by mail.messagingengine.com (Postfix) with ESMTPA id 8B75AC00E8A;\r
+ Sat, 7 Sep 2013 13:07:59 -0400 (EDT)\r
+Date: Sat, 7 Sep 2013 10:07:57 -0700\r
+From: "Kevin J. McCarthy" <kevin@8t8.us>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH v2 1/1] notmuch-mutt: Fix tagging issues\r
+Message-ID: <20130907170757.GA407@zaogao.lan>\r
+Mail-Followup-To: notmuch@notmuchmail.org, Tomi Ollila <tomi.ollila@iki.fi>,\r
+ Stefano Zacchiroli <zack@upsilon.cc>\r
+References: <20130906221520.GC4226@zaogao.lan>\r
+ <m2mwnprq7o.fsf@guru.guru-group.fi>\r
+ <20130907155748.GD4226@zaogao.lan>\r
+MIME-Version: 1.0\r
+Content-Type: multipart/signed; micalg=pgp-sha256;\r
+ protocol="application/pgp-signature"; boundary="lrZ03NoBR/3+SXJZ"\r
+Content-Disposition: inline\r
+In-Reply-To: <20130907155748.GD4226@zaogao.lan>\r
+OpenPGP: id=B6B1CD9613699FB8;\r
+ url=http://www.8t8.us/configs/13699FB8.asc.pubkey; preference=sign\r
+User-Agent: Mutt/1.5.21 (2010-09-15)\r
+Cc: Tomi Ollila <tomi.ollila@iki.fi>, Stefano Zacchiroli <zack@upsilon.cc>\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: Sat, 07 Sep 2013 17:08:12 -0000\r
+\r
+\r
+--lrZ03NoBR/3+SXJZ\r
+Content-Type: text/plain; charset=us-ascii\r
+Content-Disposition: inline\r
+Content-Transfer-Encoding: quoted-printable\r
+\r
+This patch fixes three issues with "notmuch-mutt tag":\r
+\r
+1. The message_id was not shell quoted.\r
+ Thanks to Jason Miller for the bug report and patch.\r
+\r
+2. The tags passed into tag_action() were not being properly quoted.\r
+ The "join before shell_quote" was combining multiple tags into a\r
+ single argument to notmuch tag: '+one -two -three' instead of\r
+ '+one' '-two' '-three'.\r
+\r
+3. A "--" was added between the tags and search-term as shown in the\r
+ current notmuch-tag man page.\r
+\r
+Thanks to Tomi Ollila for suggesting the simple fix of using\r
+the list form of system(), which bypasses the shell.\r
+---\r
+ contrib/notmuch-mutt/notmuch-mutt | 4 +---\r
+ 1 file changed, 1 insertion(+), 3 deletions(-)\r
+\r
+diff --git a/contrib/notmuch-mutt/notmuch-mutt b/contrib/notmuch-mutt/notmu=\r
+ch-mutt\r
+index c69b35c..4969e4b 100755\r
+--- a/contrib/notmuch-mutt/notmuch-mutt\r
++++ b/contrib/notmuch-mutt/notmuch-mutt\r
+@@ -113,9 +113,7 @@ sub tag_action(@) {\r
+ my $mid =3D get_message_id();\r
+ defined $mid or die "notmuch-mutt: cannot find Message-Id, abort.\n";\r
+=20\r
+- system("notmuch tag "\r
+- . shell_quote(join(' ', @_))\r
+- . " id:$mid");\r
++ system("notmuch", "tag", @_, "--", "id:$mid");\r
+ }\r
+=20\r
+ sub die_usage() {\r
+--=20\r
+1.8.4.rc3\r
+\r
+\r
+--lrZ03NoBR/3+SXJZ\r
+Content-Type: application/pgp-signature; name="signature.asc"\r
+Content-Description: Digital signature\r
+\r
+-----BEGIN PGP SIGNATURE-----\r
+Version: GnuPG v1.4.14 (GNU/Linux)\r
+\r
+iQEcBAEBCAAGBQJSK11tAAoJELaxzZYTaZ+4xyMH/1XSHxGqyNCZZlOaFyac9O2m\r
+OwUkyFcPoXc7p8U6BzKXBuT5/ZFoLy9wlp8n46sMw8aJL4/LTR+Mn9E0P/RpAkSE\r
+1pIPlQxFgQgnufOV3jwHZZz4DCWYJ5vAM8lZJhutbecG5RGhdhAGeqSyCNWUP2t1\r
+eIwhyNeYfAtVdnTPyntCe+NLb7V34cDiFsaBsO6egE/3FTI8/mGq2nQXSpOeZ15g\r
++6SwKnv3hRsTGGo5hdnfndhneAPEWkscMCId8G/5fBFzXkoY9YoolOS5HpF7RUxN\r
+cbRKc3jnzLa5Epb4SJoUgMKyRLsB0axH1W+uK4Wl3LIjzi6Qk0Vr2dkbxmt1Anw=\r
+=11PR\r
+-----END PGP SIGNATURE-----\r
+\r
+--lrZ03NoBR/3+SXJZ--\r