mdbx: clean zero item of DPL-list.

Change-Id: I7c60f3996783d97cee7cf2f0f9a7b856f4272641
This commit is contained in:
Leonid Yuriev 2020-12-10 14:31:21 +03:00
parent d50fff8410
commit ef7814c018

View File

@ -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;
} }