Make field volatile since it is written to outside of any locks and read
both in and out of locking.
This commit is contained in:
Timothy Bish 2016-04-26 10:03:47 -04:00
parent 4e27618ddd
commit 8031d77f98
1 changed files with 1 additions and 1 deletions

View File

@ -132,7 +132,7 @@ public class Queue extends BaseDestination implements Task, UsageListener, Index
private boolean allConsumersExclusiveByDefault = false;
private final AtomicBoolean started = new AtomicBoolean();
private boolean resetNeeded;
private volatile boolean resetNeeded;
private final Runnable sendMessagesWaitingForSpaceTask = new Runnable() {
@Override