Closed vinser52 closed 1 year ago
In this PR I have fixed the moveRegularItemOnEviction
function. The fix contains the following:
moveRegularItemOnEviction
function. The function tries to move the content of the oldItem
to the newItemHdl
in order to recycle the oldItem
. If the function succeeds it returns the handle to the oldItem
, so that it can be reused for the new stuff. Otherwise, it returns an empty handle.replaceInMMContainer(oldItemPtr, *newItemHdl)
or newItemHdl->isAccessible()
return false
it means some concurrent thread removed this key or called inserOrReplace, but we still can recycle the oldItem
.moveRegularItemOnEviction
because this function intended to work only with regular Items and we have no logic for chainedItem yet.
@igchor Please review
This change is