Fixing missing volatile on references in VMTransport to prevent a synchronization bug.

This resolves https://issues.apache.org/jira/browse/AMQ-5787
This commit is contained in:
Christopher L. Shannon (cshannon) 2015-05-20 18:38:59 +00:00 committed by Timothy Bish
parent f05ff94e5c
commit e99c814830
1 changed files with 3 additions and 3 deletions

View File

@ -56,9 +56,9 @@ public class VMTransport implements Transport, Task {
protected final long id;
// Implementation
private LinkedBlockingQueue<Object> messageQueue;
private TaskRunnerFactory taskRunnerFactory;
private TaskRunner taskRunner;
private volatile LinkedBlockingQueue<Object> messageQueue;
private volatile TaskRunnerFactory taskRunnerFactory;
private volatile TaskRunner taskRunner;
// Transport State
protected final AtomicBoolean started = new AtomicBoolean();