Ensure unmodified buffer delivered via pipeline after read completes but before next read begins.

This commit is contained in:
John Fallows 2012-08-13 23:16:07 -07:00
parent 11c742f392
commit cd8e2576b4

View File

@ -308,7 +308,6 @@ public class AioSocketChannel extends AbstractAioChannel implements SocketChanne
// This is needed as the ByteBuffer and the ByteBuf does not share
// each others index
byteBuf.writerIndex(byteBuf.writerIndex() + localReadAmount);
expandReadBuffer(byteBuf);
read = true;
} else if (localReadAmount < 0) {
@ -372,9 +371,9 @@ public class AioSocketChannel extends AbstractAioChannel implements SocketChanne
@Override
protected void completed0(Void result, AioSocketChannel channel) {
channel.beginRead();
((AbstractAioUnsafe) channel.unsafe()).connectSuccess();
channel.pipeline().fireChannelActive();
channel.beginRead();
}
@Override