HBASE-26992 Brotli compressor has unexpected behavior during reinitialization (#4389)
Signed-off-by: Duo Zhang <zhangduo@apache.org>
This commit is contained in:
parent
afb8afd26c
commit
191e932944
|
@ -162,8 +162,8 @@ public class BrotliCompressor implements CanReinit, Compressor {
|
|||
int newBufferSize = BrotliCodec.getBufferSize(conf);
|
||||
if (bufferSize != newBufferSize) {
|
||||
bufferSize = newBufferSize;
|
||||
this.inBuf = ByteBuffer.allocateDirect(bufferSize);
|
||||
this.outBuf = ByteBuffer.allocateDirect(bufferSize);
|
||||
this.inBuf = ByteBuffer.allocate(bufferSize);
|
||||
this.outBuf = ByteBuffer.allocate(bufferSize);
|
||||
}
|
||||
}
|
||||
reset();
|
||||
|
|
Loading…
Reference in New Issue