]> git.notmuchmail.org Git - notmuch/blobdiff - lib/query.cc
notmuch search: Print the number of matched/total messages for each thread.
[notmuch] / lib / query.cc
index 381529b538c270695144d4aef8ae7ba673dee996..e853d4ec8e46b55b260fc0264b1756bf59eb26a1 100644 (file)
@@ -220,7 +220,8 @@ notmuch_query_search_threads (notmuch_query_t *query,
            {
                if (threads_seen >= first) {
                    thread = _notmuch_thread_create (query, query->notmuch,
-                                                    thread_id);
+                                                    thread_id,
+                                                    query->query_string);
                    g_ptr_array_add (threads->threads, thread);
                } else {
                    thread = NULL;
@@ -231,9 +232,6 @@ notmuch_query_search_threads (notmuch_query_t *query,
                threads_seen++;
            }
 
-           if (thread)
-               _notmuch_thread_add_message (thread, message);
-
            notmuch_message_destroy (message);
 
            messages_seen++;