AIO: Act on the right ByteBuf when a exception was caught during write

This commit is contained in:
Norman Maurer 2012-07-09 17:27:20 +02:00
parent e157ea1a66
commit d233be7041

View File

@ -224,7 +224,7 @@ public class AioSocketChannel extends AbstractAioChannel implements SocketChanne
channel.notifyFlushFutures(cause);
channel.pipeline().fireExceptionCaught(cause);
ByteBuf buf = channel.pipeline().outboundByteBuffer();
ByteBuf buf = channel.unsafe().directOutboundContext().outboundByteBuffer();
if (!buf.readable()) {
buf.discardReadBytes();
}