From: Carl Worth Date: Sun, 25 Oct 2009 05:20:13 +0000 (-0700) Subject: Fix bit-twiddling brain damage in notmuch_query_search X-Git-Tag: 0.1~728 X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=commitdiff_plain;h=15d949b7404b322df39e2aae7a5653e4cf8a8dc9;hp=526b7144f7d692e04ce950dfa7d0ee1bdf792cdc Fix bit-twiddling brain damage in notmuch_query_search Here's the big bug that was preventing any searches from working at all like desired. I did the work to carefully pick out exactly the flags that I wanted, and then I threw it away by trying to combine them with & instead of | (so just passing 0 for flags instead). Much better now. --- diff --git a/query.cc b/query.cc index f66ee556..57501675 100644 --- a/query.cc +++ b/query.cc @@ -95,10 +95,10 @@ notmuch_query_search (notmuch_query_t *query) Xapian::Query mail_query ("Kmail"); Xapian::Query string_query, final_query; Xapian::MSet mset; - unsigned int flags = (Xapian::QueryParser::FLAG_BOOLEAN & - Xapian::QueryParser::FLAG_PHRASE & - Xapian::QueryParser::FLAG_LOVEHATE & - Xapian::QueryParser::FLAG_BOOLEAN_ANY_CASE & + unsigned int flags = (Xapian::QueryParser::FLAG_BOOLEAN | + Xapian::QueryParser::FLAG_PHRASE | + Xapian::QueryParser::FLAG_LOVEHATE | + Xapian::QueryParser::FLAG_BOOLEAN_ANY_CASE | Xapian::QueryParser::FLAG_WILDCARD); if (strcmp (query_string, "") == 0) {