]> git.notmuchmail.org Git - notmuch/commitdiff
lib: search_threads: Fix nested search to handle original search of "*"
authorCarl Worth <cworth@cworth.org>
Thu, 15 Apr 2010 16:15:10 +0000 (09:15 -0700)
committerCarl Worth <cworth@cworth.org>
Thu, 15 Apr 2010 21:54:40 +0000 (14:54 -0700)
When constructing a thread, we usually run a nested query to find all
messages in the thread that match the original search string. However,
we need to have special-case handling of an original search string of
"*" now that that is a supported means of specifying all messages.

The special-case ends up bein quite simple---we do less work, (just
skipping the nested search since we know that all messages must
match). I had been wanting to write this identical code to more
efficiently handle "notmuch search thread:<foo>" which was previously
running two identical searches. So that case is now more efficient as
well.


No differences found