No-op GlassTable::readahead_key for overlong keys
commite2c644d915d9eac0e975b5ed03ec51c49a43efd9
authorRobert Stepanek <rsto@paranoia.at>
Mon, 17 Aug 2020 13:18:36 +0000 (17 15:18 +0200)
committerOlly Betts <olly@survex.com>
Wed, 19 Aug 2020 23:55:21 +0000 (20 11:55 +1200)
tree25721128c22d54c1bdd03f49072d56ba9f9308e0
parent2c88d60194f5f081b3d2ebeedbac5c375ca6fd6e
No-op GlassTable::readahead_key for overlong keys

Currently, a query may abort with an InvalidArgument error if one of
the terms exceeds the maximum allowed length for glass btree keys.
However, this error is thrown only if the query triggers a readahead_key
call on the glass table.

This patch updates readahead_key to report overlong keys as not found,
rather than aborting the whole query.

Closes https://github.com/xapian/xapian/pull/313
xapian-core/backends/glass/glass_table.cc
xapian-core/tests/api_backend.cc