Skip to content

Commit

Permalink
Review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
NiteshKant committed Sep 14, 2021
1 parent 53a54ff commit 48acfdf
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -402,7 +402,7 @@ protected void decodeLast(ChannelHandlerContext ctx, Buffer in) throws Exception
private static Buffer expandCumulationAndWrite(BufferAllocator alloc, Buffer oldCumulation, Buffer in) {
final int newSize = safeFindNextPositivePowerOfTwo(oldCumulation.readableBytes() + in.readableBytes());
Buffer newCumulation = oldCumulation.readOnly() ? alloc.allocate(newSize) :
oldCumulation.ensureWritable(newSize, in.readableBytes(), true);
oldCumulation.ensureWritable(newSize);
try {
if (newCumulation != oldCumulation) {
newCumulation.writeBytes(oldCumulation);
Expand Down

0 comments on commit 48acfdf

Please sign in to comment.