Sho SHIMIZU
Committed by Thomas Vachuska

Read the latest value of dispatchFuture

The field, dispatchFuture, is accessed in activate() method and the thread
where Watchdog is running. Then, different threads could access the field
and couldn't read the latest value.

Change-Id: Iceb390bcf3c5711c1dbb59198667138c8a90b036
...@@ -71,7 +71,7 @@ public class CoreEventDispatcher extends DefaultEventSinkRegistry ...@@ -71,7 +71,7 @@ public class CoreEventDispatcher extends DefaultEventSinkRegistry
71 private TimerTask watchdog; 71 private TimerTask watchdog;
72 private EventSink lastSink; 72 private EventSink lastSink;
73 private final AtomicLong lastStart = new AtomicLong(0); 73 private final AtomicLong lastStart = new AtomicLong(0);
74 - private Future<?> dispatchFuture; 74 + private volatile Future<?> dispatchFuture;
75 75
76 @Override 76 @Override
77 public void post(Event event) { 77 public void post(Event event) {
......