Ensure unmodified buffer delivered via pipeline after read completes but before next read begins.
This commit is contained in:
parent
11c742f392
commit
cd8e2576b4
@ -308,7 +308,6 @@ public class AioSocketChannel extends AbstractAioChannel implements SocketChanne
|
|||||||
// This is needed as the ByteBuffer and the ByteBuf does not share
|
// This is needed as the ByteBuffer and the ByteBuf does not share
|
||||||
// each others index
|
// each others index
|
||||||
byteBuf.writerIndex(byteBuf.writerIndex() + localReadAmount);
|
byteBuf.writerIndex(byteBuf.writerIndex() + localReadAmount);
|
||||||
expandReadBuffer(byteBuf);
|
|
||||||
|
|
||||||
read = true;
|
read = true;
|
||||||
} else if (localReadAmount < 0) {
|
} else if (localReadAmount < 0) {
|
||||||
@ -372,9 +371,9 @@ public class AioSocketChannel extends AbstractAioChannel implements SocketChanne
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void completed0(Void result, AioSocketChannel channel) {
|
protected void completed0(Void result, AioSocketChannel channel) {
|
||||||
channel.beginRead();
|
|
||||||
((AbstractAioUnsafe) channel.unsafe()).connectSuccess();
|
((AbstractAioUnsafe) channel.unsafe()).connectSuccess();
|
||||||
channel.pipeline().fireChannelActive();
|
channel.pipeline().fireChannelActive();
|
||||||
|
channel.beginRead();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user