Make use of the existance of bridge references to find a buffer

This commit is contained in:
Trustin Lee 2012-06-04 11:18:48 -07:00
parent c8c577efc5
commit 1a9c0fd569

View File

@ -621,8 +621,7 @@ public class DefaultChannelPipeline implements ChannelPipeline {
if (ctx == null) {
return false;
}
ChannelBufferHolder<Object> in = ctx.in;
if (in != null && !in.isBypass() && in.hasByteBuffer()) {
if (ctx.inByteBridge != null) {
return true;
}
ctx = ctx.next;
@ -634,8 +633,7 @@ public class DefaultChannelPipeline implements ChannelPipeline {
if (ctx == null) {
return false;
}
ChannelBufferHolder<Object> in = ctx.inbound();
if (in != null && !in.isBypass() && in.hasMessageBuffer()) {
if (ctx.inMsgBridge != null) {
return true;
}
ctx = ctx.next;
@ -699,8 +697,7 @@ public class DefaultChannelPipeline implements ChannelPipeline {
return false;
}
ChannelBufferHolder<Object> out = ctx.outbound();
if (out != null && !out.isBypass() && out.hasByteBuffer()) {
if (ctx.outByteBridge != null) {
return true;
}
ctx = ctx.prev;
@ -713,8 +710,7 @@ public class DefaultChannelPipeline implements ChannelPipeline {
return false;
}
ChannelBufferHolder<Object> out = ctx.outbound();
if (out != null && !out.isBypass() && out.hasMessageBuffer()) {
if (ctx.outMsgBridge != null) {
return true;
}
ctx = ctx.prev;