Update src/main/java/org/jboss/netty/handler/queue/BufferedWriteHandler.java
fix bug, flush variable was never reset
This commit is contained in:
parent
c3af4427bb
commit
3de2d06971
@ -254,6 +254,7 @@ public class BufferedWriteHandler extends SimpleChannelHandler implements LifeCy
|
||||
final Queue<MessageEvent> queue = getQueue();
|
||||
if (consolidateOnFlush) {
|
||||
if (queue.isEmpty()) {
|
||||
flush.set(false);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -283,7 +284,8 @@ public class BufferedWriteHandler extends SimpleChannelHandler implements LifeCy
|
||||
ctx.sendDownstream(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
flush.set(false);
|
||||
}
|
||||
|
||||
if (acquired && (!channel.isConnected() || channel.isWritable() && !queue.isEmpty())) {
|
||||
flush(consolidateOnFlush);
|
||||
|
Loading…
Reference in New Issue
Block a user