https://bugs.openldap.org/show_bug.cgi?id=9291
--- Comment #19 from Markus markus@objectbox.io --- (In reply to Howard Chu from comment #18)
It's possible for some pages to be dirtied at the end of the file, but then get deleted/unused again before the txn commits.
I was able to reproduce this scenario and I don't see how mm_last_pg could be used in testing. Did I miss something? So, unless you have a better idea, I guess I'm back to my initially proposed patch.