X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=query.cc;h=f66ee55649767639006fade6c22a6e963848adb7;hp=a15de9664a5ac4b8d15f5e567f873364a39d2f9a;hb=526b7144f7d692e04ce950dfa7d0ee1bdf792cdc;hpb=144b2cbc5532e000c37b4d5ba7bb5d9ea113859f diff --git a/query.cc b/query.cc index a15de966..f66ee556 100644 --- a/query.cc +++ b/query.cc @@ -41,6 +41,10 @@ notmuch_query_create (notmuch_database_t *notmuch, { notmuch_query_t *query; +#ifdef DEBUG_QUERY + fprintf (stderr, "Query string is:\n%s\n", query_string); +#endif + query = talloc (NULL, notmuch_query_t); if (unlikely (query == NULL)) return NULL; @@ -118,6 +122,10 @@ notmuch_query_search (notmuch_query_t *query) break; } +#if DEBUG_QUERY + fprintf (stderr, "Final query is:\n%s\n", final_query.get_description().c_str()); +#endif + enquire.set_query (final_query); mset = enquire.get_mset (0, notmuch->xapian_db->get_doccount ());