Make sure that all files are closed upon attempts to open a DB with
broken content.