diff --git a/java/core/src/test/org/apache/orc/impl/TestBrotli.java b/java/core/src/test/org/apache/orc/impl/TestBrotli.java index e5d23ca452..1cc9f8d2ee 100644 --- a/java/core/src/test/org/apache/orc/impl/TestBrotli.java +++ b/java/core/src/test/org/apache/orc/impl/TestBrotli.java @@ -138,7 +138,7 @@ public void testDirectDecompress() { brotliCodec.getDefaultOptions())); out.flip(); // copy heap buffer to direct buffer. - directOut.put(out.array()); + directOut.put(out); directOut.flip(); brotliCodec.decompress(directOut, directResult);