From 6554a5df3a807911922673bc46b1b74fb16c6087 Mon Sep 17 00:00:00 2001
From: Chong Yidong <cyd@stupidchicken.com>
Date: Fri, 15 Jan 2010 11:55:43 -0500
Subject: [PATCH] * net/mairix.el (mairix-widget-send-query): Send -1 instead
 of nil to mairix-search to suppress threading (Bug#5342).

---
 lisp/ChangeLog     | 5 +++++
 lisp/net/mairix.el | 6 ++----
 2 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index b0cdf71dab4..9e08889ba61 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
+2010-01-15   David Abrahams  <dave@boostpro.com>  (tiny change)
+
+	* net/mairix.el (mairix-widget-send-query): Send -1 instead of nil
+	to mairix-search to suppress threading (Bug#5342).
+
 2010-01-15  Kenichi Handa  <handa@m17n.org>
 
 	* international/mule-cmds.el (canonicalize-coding-system-name):
diff --git a/lisp/net/mairix.el b/lisp/net/mairix.el
index b5fb92e5c6f..1974427c829 100644
--- a/lisp/net/mairix.el
+++ b/lisp/net/mairix.el
@@ -341,7 +341,7 @@ Currently there are 'threads and 'flags.")
 
 (defun mairix-search (search threads)
   "Call Mairix with SEARCH.
-If THREADS is t, also display whole threads of found
+If THREADS is non-nil, also display whole threads of found
 messages.  Results will be put into the default search file."
   (interactive
    (list
@@ -595,9 +595,7 @@ See %s for details" mairix-output-buffer)))
   "Send query from WIDGETS to mairix binary."
   (mairix-search
    (mairix-widget-make-query-from-widgets widgets)
-   (if (widget-value (cadr (assoc "Threads" widgets)))
-       t
-     -1))
+   (if (widget-value (cadr (assoc "Threads" widgets))) t))
   (kill-buffer mairix-customize-query-buffer))
 
 (defun mairix-widget-save-search (widgets)
-- 
2.39.5