mirror of
https://github.com/MariaDB/server.git
synced 2025-02-02 12:01:42 +01:00
git-svn-id: file:///svn/tokudb@4258 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
parent
d4a80654d1
commit
0c5f094e26
1 changed files with 3 additions and 2 deletions
|
@ -1405,12 +1405,13 @@ static int brt_leaf_apply_cmd_once (BRT t, BRTNODE node, BRT_CMD cmd, TOKULOGGER
|
|||
node->u.l.n_bytes_in_buffer -= OMT_ITEM_OVERHEAD + leafentry_disksize(le);
|
||||
node->local_fingerprint -= node->rand4fingerprint * toku_le_crc(le);
|
||||
|
||||
toku_mempool_mfree(&node->u.l.buffer_mempool, 0, leafentry_memsize(le)); // Must pass 0, since le may be no good any more.
|
||||
|
||||
LEAFENTRY new_le = mempool_malloc_from_omt(node->u.l.buffer, &node->u.l.buffer_mempool, newlen);
|
||||
assert(new_le);
|
||||
memcpy(new_le, newdata, newlen);
|
||||
|
||||
// This mfree must occur after the mempool_malloc so that
|
||||
toku_mempool_mfree(&node->u.l.buffer_mempool, 0, leafentry_memsize(le)); // Must pass 0, since le may be no good any more.
|
||||
|
||||
node->u.l.n_bytes_in_buffer += OMT_ITEM_OVERHEAD + newdisksize;
|
||||
node->local_fingerprint += node->rand4fingerprint*toku_le_crc(newdata);
|
||||
toku_free(newdata);
|
||||
|
|
Loading…
Add table
Reference in a new issue