Made sure that NioWorker.wakenUp is set to true only when its selector is really waken up
This commit is contained in:
parent
79fe2324c9
commit
ea1a68cb83
@ -386,9 +386,9 @@ class NioWorker implements Runnable {
|
||||
if (channel.writeTaskInTaskQueue.compareAndSet(false, true)) {
|
||||
worker.writeTaskQueue.offer(channel.writeTask);
|
||||
}
|
||||
if (worker.wakenUp.compareAndSet(false, true)) {
|
||||
Selector workerSelector = worker.selector;
|
||||
if (workerSelector != null) {
|
||||
if (worker.wakenUp.compareAndSet(false, true)) {
|
||||
workerSelector.wakeup();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user