mirror of
https://github.com/isar/libmdbx.git
synced 2024-10-30 11:29:19 +08:00
mdbx: clean zero item of DPL-list.
Change-Id: I7c60f3996783d97cee7cf2f0f9a7b856f4272641
This commit is contained in:
parent
d50fff8410
commit
ef7814c018
@ -3014,6 +3014,8 @@ static MDBX_dpl *mdbx_dpl_reserve(MDBX_txn *txn, size_t size) {
|
|||||||
bytes = malloc_usable_size(dl);
|
bytes = malloc_usable_size(dl);
|
||||||
#endif /* malloc_usable_size */
|
#endif /* malloc_usable_size */
|
||||||
dl->allocated = bytes2dpl(bytes);
|
dl->allocated = bytes2dpl(bytes);
|
||||||
|
dl->items[0].pgno = 0;
|
||||||
|
dl->items[0].ptr = nullptr;
|
||||||
mdbx_tassert(txn, txn->tw.dirtylist == NULL || dl->length <= dl->allocated);
|
mdbx_tassert(txn, txn->tw.dirtylist == NULL || dl->length <= dl->allocated);
|
||||||
txn->tw.dirtylist = dl;
|
txn->tw.dirtylist = dl;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user