Treating only MDB_NOTFOUND as an error leads to use of uninitliazed
pointers and handle IDs in other cases (e.g. when get fails with
MDB_BAD_TXN) and wreaks havoc in the application.
This is a bit of a hacky fix since long-term solution probably requires
more rigorous refactoring of the Baloo Engine. There's a lot of
duplicate code and uninitialized values, which makes it hard to track
the misuse of LMDB API.
However this should fix a good deal of crashes, probably more.
BUG: 361186
BUG: 390823
BUG: 372880
BUG: 395888
BUG: 367480
BUG: 403720