diff --git a/libraries/liblmdb/mdb.c b/libraries/liblmdb/mdb.c index dff463b..438838f 100644 --- a/libraries/liblmdb/mdb.c +++ b/libraries/liblmdb/mdb.c @@ -3707,10 +3707,14 @@ void mdb_env_close(MDB_env *env) { MDB_page *dp; + int i; if (env == NULL) return; + for (i = env->me_numdbs; --i > MAIN_DBI; ) + free(env->me_dbxs[i].md_name.mv_data); + VGMEMP_DESTROY(env); while ((dp = env->me_dpages) != NULL) { VGMEMP_DEFINED(&dp->mp_next, sizeof(dp->mp_next));