There is a bug in the exclude code (found by jrollins in the --with-excluded series) but also present in master. None of the current tests were finding it so the first patch adds two tests. The bug (and test failure) do not appear in all configuations: on my main test machine (an oldish debian testing 32bit userspace with a 64bit kernel and xapian 1.2.7) all tests pass. On my laptop (a recent debian testing 64bit userspace and xapian 1.2.8) one of the new tests fails. The second patch fixes the behaviour for me but I don't see why it should make a difference: searches for A and not B should give the same results as A and not (A and B). It could be a bug in xapian, it could be that I am not allowed to reuse queries as I do (is query1 = query1 and query2 allowed?) or it could be some memory use bug on my part. Anyway the "fix" is small which should help narrow down the actual cause. Best wishes Mark Mark Walters (2): test: add tests for message only search lib: fix an exclude bug lib/query.cc | 5 +++-- test/search | 11 +++++++++++ 2 files changed, 14 insertions(+), 2 deletions(-) -- 1.7.9.1