ioread() now throws DatabaseCorruptError on EOF
commitf8d260706329528a7684b3c3f656d89dd51120b3
authorOlly Betts <olly@survex.com>
Fri, 26 Feb 2016 00:03:54 +0000 (26 13:03 +1300)
committerOlly Betts <olly@survex.com>
Fri, 26 Feb 2016 00:03:54 +0000 (26 13:03 +1300)
tree720d0144c7a9c9630a0b0508664a0da727d6542a
parent107033e20e8b23edc1d12c1db9446a58142a4f44
ioread() now throws DatabaseCorruptError on EOF

This gives a more helpful error for all existing callers where min is
non-zero, and in particular means glass gives DatabaseCorruptError if
all the files in a DB are truncated to zero size (which makes it
consistent with chert).
xapian-core/common/io_utils.cc
xapian-core/common/io_utils.h