lib: Add exclude query debug output

This commit is contained in:
Austin Clements 2012-03-13 22:31:31 -04:00 committed by David Bremner
parent 75a0552633
commit 28367a9bcd

View file

@ -261,9 +261,12 @@ notmuch_query_search_messages (notmuch_query_t *query)
break;
}
if (_debug_query ())
if (_debug_query ()) {
fprintf (stderr, "Exclude query is:\n%s\n",
exclude_query.get_description ().c_str ());
fprintf (stderr, "Final query is:\n%s\n",
final_query.get_description ().c_str ());
}
enquire.set_query (final_query);
@ -537,9 +540,12 @@ notmuch_query_count_messages (notmuch_query_t *query)
enquire.set_weighting_scheme(Xapian::BoolWeight());
enquire.set_docid_order(Xapian::Enquire::ASCENDING);
if (_debug_query ())
if (_debug_query ()) {
fprintf (stderr, "Exclude query is:\n%s\n",
exclude_query.get_description ().c_str ());
fprintf (stderr, "Final query is:\n%s\n",
final_query.get_description ().c_str ());
}
enquire.set_query (final_query);