Release the cumulation buffer after firing upstream so we don't end up

with a "leak" because of a very big ChannelBuffer. This patch is
extracted of the pull request 39. Thanks to arya for the patch. See
NETTY-453
This commit is contained in:
Norman Maurer 2011-11-03 11:29:39 +01:00
parent 5860ce337d
commit 24e0b01e8d

View File

@ -298,6 +298,10 @@ public abstract class FrameDecoder extends SimpleChannelUpstreamHandler {
unfoldAndFireMessageReceived(context, remoteAddress, frame);
}
if (!cumulation.readable()) {
this.cumulation = null;
}
}
private void unfoldAndFireMessageReceived(ChannelHandlerContext context, SocketAddress remoteAddress, Object result) {