thanks rpm developers : ) https://github.com/rpm-software-management/rpm/blob/master/lib/backend/lmdb.c