Removed unnecessary conditional statement

This commit is contained in:
Trustin Lee 2009-10-27 08:49:13 +00:00
parent 698f8d54eb
commit 2663f85936

View File

@ -361,7 +361,7 @@ class NioWorker implements Runnable {
final NioWorker worker = channel.worker; final NioWorker worker = channel.worker;
final Thread currentThread = Thread.currentThread(); final Thread currentThread = Thread.currentThread();
final Thread workerThread = worker.thread; final Thread workerThread = worker.thread;
if (workerThread == null || currentThread != workerThread) { if (currentThread != workerThread) {
if (channel.writeTaskInTaskQueue.compareAndSet(false, true)) { if (channel.writeTaskInTaskQueue.compareAndSet(false, true)) {
boolean offered = worker.writeTaskQueue.offer(channel.writeTask); boolean offered = worker.writeTaskQueue.offer(channel.writeTask);
assert offered; assert offered;