mirror of
https://github.com/isar/libmdbx.git
synced 2025-01-30 22:47:16 +08:00
all: refine #defines that controls memory checking.
LDAP_DISABLE_MEMORY_CHECK removed, LDAP_MEMORY_DEBUG is used instead. LDAP_MEMORY_DEBUG_ASSERT replaced with LDAP_MEMORY_ASSERT. Change-Id: I0f43b9ae10b76c1af39f2c52b34b4ab804521e78
This commit is contained in:
parent
9a76b0a008
commit
4a1574c998
4
mdb.c
4
mdb.c
@ -1816,7 +1816,7 @@ mdb_page_malloc(MDB_txn *txn, unsigned num)
|
||||
VALGRIND_MEMPOOL_ALLOC(env, np, size);
|
||||
}
|
||||
|
||||
#ifdef LDAP_MEMORY_DEBUG
|
||||
#if LDAP_MEMORY_DEBUG > 0
|
||||
memset(np, 42, size);
|
||||
#else
|
||||
if ((env->me_flags & MDB_NOMEMINIT) == 0) {
|
||||
@ -2508,7 +2508,7 @@ search_done:
|
||||
txn->mt_next_pgno = pgno + num;
|
||||
}
|
||||
|
||||
#ifdef LDAP_MEMORY_DEBUG
|
||||
#if LDAP_MEMORY_DEBUG > 0
|
||||
memset(np, 111, env->me_psize * num);
|
||||
#endif
|
||||
VALGRIND_MAKE_MEM_UNDEFINED(np, env->me_psize * num);
|
||||
|
Loading…
x
Reference in New Issue
Block a user