mirror of
https://github.com/OpenHFT/Chronicle-Map.git
synced 2021-09-13 01:26:12 +00:00
Fix wrong decrements of tierDeleted (after innerDefaultReplaceValue(), when should be before), because relocation could trigger tier change inside innerDefaultReplaceValue()
This commit is contained in:
+1
-1
@@ -134,8 +134,8 @@ public abstract class ReplicatedMapSegmentIteration<K, V, R> extends MapSegmentI
|
||||
checkOnEachPublicOperation.checkOnEachPublicOperation();
|
||||
if (e.entryDeleted()) {
|
||||
try {
|
||||
e.innerDefaultReplaceValue(value);
|
||||
s.tierDeleted(s.tierDeleted() - 1);
|
||||
e.innerDefaultReplaceValue(value);
|
||||
s.incrementModCount();
|
||||
e.writeEntryPresent();
|
||||
ru.updateChange();
|
||||
|
||||
@@ -52,9 +52,9 @@ public abstract class ReplicatedMapAbsent<K, V> extends MapAbsent<K, V> {
|
||||
ks.setSearchState(PRESENT);
|
||||
q.initPresenceOfEntry(EntryPresence.PRESENT);
|
||||
} else {
|
||||
s.tierDeleted(s.tierDeleted() - 1);
|
||||
e.innerDefaultReplaceValue(value);
|
||||
e.updatedReplicationStateOnPresentEntry();
|
||||
s.tierDeleted(s.tierDeleted() - 1);
|
||||
}
|
||||
s.incrementModCount();
|
||||
e.writeEntryPresent();
|
||||
|
||||
Reference in New Issue
Block a user