--- /dev/null
+Return-Path: <markwalters1009@gmail.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 174FB431FB6\r
+ for <notmuch@notmuchmail.org>; Wed, 22 Feb 2012 00:47:50 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0.201\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0.201 tagged_above=-999 required=5\r
+ tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
+ FREEMAIL_ENVFROM_END_DIGIT=1, FREEMAIL_FROM=0.001,\r
+ 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 mWa3zlmXZu3i for <notmuch@notmuchmail.org>;\r
+ Wed, 22 Feb 2012 00:47:49 -0800 (PST)\r
+Received: from mail-wi0-f181.google.com (mail-wi0-f181.google.com\r
+ [209.85.212.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+ (No client certificate requested)\r
+ by olra.theworths.org (Postfix) with ESMTPS id 5C7A5431FAE\r
+ for <notmuch@notmuchmail.org>; Wed, 22 Feb 2012 00:47:49 -0800 (PST)\r
+Received: by wibhi8 with SMTP id hi8so4863183wib.26\r
+ for <notmuch@notmuchmail.org>; Wed, 22 Feb 2012 00:47:48 -0800 (PST)\r
+Received-SPF: pass (google.com: domain of markwalters1009@gmail.com designates\r
+ 10.216.139.147 as permitted sender) client-ip=10.216.139.147; \r
+Authentication-Results: mr.google.com; spf=pass (google.com: domain of\r
+ markwalters1009@gmail.com designates 10.216.139.147 as\r
+ permitted sender) smtp.mail=markwalters1009@gmail.com;\r
+ dkim=pass header.i=markwalters1009@gmail.com\r
+Received: from mr.google.com ([10.216.139.147])\r
+ by 10.216.139.147 with SMTP id c19mr8700195wej.11.1329900468054\r
+ (num_hops = 1); Wed, 22 Feb 2012 00:47:48 -0800 (PST)\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma;\r
+ h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references;\r
+ bh=lwAHsnS6wOXMaLbCgs+BGP+Snl8mcyVBK/MB1Cc/zU4=;\r
+ b=niJTtOZaTy9uV4acg6WJn4ZdcGrpfmjvnTrv2QcMMR2oNRXqpj/It0TKcwWH3dJZq6\r
+ LCInFTKeu8N2dbEmWUugsqg36tjvgaUy9tcF8ELwStr9MR1uY7jUvNNuuoea0wO6aqtU\r
+ UGEHaxyXpohbRObjhrSFibPF6wbTmVoi71V/s=\r
+Received: by 10.216.139.147 with SMTP id c19mr7215622wej.11.1329900468005;\r
+ Wed, 22 Feb 2012 00:47:48 -0800 (PST)\r
+Received: from localhost (94-192-233-223.zone6.bethere.co.uk.\r
+ [94.192.233.223]) by mx.google.com with ESMTPS id\r
+ n5sm68141576wiw.7.2012.02.22.00.47.46 (version=TLSv1/SSLv3 cipher=OTHER);\r
+ Wed, 22 Feb 2012 00:47:47 -0800 (PST)\r
+From: Mark Walters <markwalters1009@gmail.com>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH] emacs: initialize ido mode in notmuch-mua.el\r
+Date: Wed, 22 Feb 2012 08:48:49 +0000\r
+Message-Id: <1329900529-16295-1-git-send-email-markwalters1009@gmail.com>\r
+X-Mailer: git-send-email 1.7.2.3\r
+In-Reply-To: <87y5sipcjn.fsf@qmul.ac.uk>\r
+References: <87y5sipcjn.fsf@qmul.ac.uk>\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: Wed, 22 Feb 2012 08:47:50 -0000\r
+\r
+ido-completing-read is used in notmuch-mua.el without any\r
+initialization. This should work but a bug (emacs bug #3247) in some\r
+emacs 23 versions (including 23.2.1 from Debian stable) causes emacs\r
+to get stuck in the mini-buffer. This tests to see if ido-mode has\r
+been initialized and if not calls it. This avoids the bug for these\r
+older versions of emacs.\r
+\r
+This is the only place that ido-completing-read is used so an alternative \r
+would be to replace ido-completing-read by completing-read but cworth \r
+expressed a preference for the ido version in \r
+id:"87wrhfvk6a.fsf@yoom.home.cworth.org"\r
+\r
+\r
+---\r
+ emacs/notmuch-mua.el | 2 ++\r
+ 1 files changed, 2 insertions(+), 0 deletions(-)\r
+\r
+diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el\r
+index 4be7c13..9fe75db 100644\r
+--- a/emacs/notmuch-mua.el\r
++++ b/emacs/notmuch-mua.el\r
+@@ -194,6 +194,8 @@ the From: header is already filled in by notmuch."\r
+ addresses (cons (notmuch-user-primary-email) (notmuch-user-other-email))\r
+ one-name-only t))\r
+ ;; Now prompt the user, either for an email address only or for a full identity.\r
++ (unless ido-mode\r
++ (ido-mode t))\r
+ (if one-name-only\r
+ (let ((address\r
+ (ido-completing-read (concat "Sender address for " name ": ") addresses\r
+-- \r
+1.7.2.3\r
+\r