HBASE-26992 Brotli compressor has unexpected behavior during reinitialization (#4389)
Signed-off-by: Duo Zhang <zhangduo@apache.org>
This commit is contained in:
parent
adc9d07385
commit
22211d2b27
|
@ -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