Atomic instead of volatile to match counter
This commit is contained in:
1 parent
ba94fabfb8
commit
ad2cde9d85
1 file changed
+2
-2
@@ -150,7 +150,7 @@ public class ItemProductionMsgHandler extends AbstractClientMsgHandler {
|
||||
ForgeManager.itemWorkOrderLookup.remove(virtualItem);
|
||||
DbManager.removeFromCache(virtualItem);
|
||||
|
||||
workOrder.slots_used.set(workOrder.slots_used.get() - 1);
|
||||
workOrder.slots_used.decrementAndGet();
|
||||
|
||||
// Update workOrder on disk
|
||||
|
||||
@@ -429,7 +429,7 @@ public class ItemProductionMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
// Slot is no longer allocated to this workOrder.
|
||||
|
||||
workOrder.slots_used.set(workOrder.slots_used.get() - 1);
|
||||
workOrder.slots_used.decrementAndGet();
|
||||
|
||||
// Update workOrder on disk
|
||||
|
||||
|
||||
Reference in new issue
Block a user