From 0fd824c3bb2382df4ab9495810bab20150db3960 Mon Sep 17 00:00:00 2001 From: Trustin Lee Date: Thu, 31 May 2012 09:11:07 -0700 Subject: [PATCH] Fix UnsupportedOperationException --- .../src/main/java/io/netty/channel/DefaultChannelPipeline.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/transport/src/main/java/io/netty/channel/DefaultChannelPipeline.java b/transport/src/main/java/io/netty/channel/DefaultChannelPipeline.java index a891893773..d0425ac116 100644 --- a/transport/src/main/java/io/netty/channel/DefaultChannelPipeline.java +++ b/transport/src/main/java/io/netty/channel/DefaultChannelPipeline.java @@ -742,7 +742,7 @@ public class DefaultChannelPipeline implements ChannelPipeline { notifyHandlerException(t); } finally { ChannelBufferHolder inbound = ctx.inbound(); - if (inbound.isEmpty() && inbound.hasByteBuffer()) { + if (!inbound.isBypass() && inbound.isEmpty() && inbound.hasByteBuffer()) { inbound.byteBuffer().discardReadBytes(); } }