From 076618677d3524187e5be4b5401e25a9ca154230 Mon Sep 17 00:00:00 2001 From: cxorm Date: Sat, 15 Jun 2019 11:05:20 +0800 Subject: [PATCH] HADOOP-16336. finish variable is unused in ZStandardCompressor. Contributed by cxorm. --- .../apache/hadoop/io/compress/zstd/ZStandardCompressor.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/compress/zstd/ZStandardCompressor.java b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/compress/zstd/ZStandardCompressor.java index 7445502c98..716a19886f 100644 --- a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/compress/zstd/ZStandardCompressor.java +++ b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/compress/zstd/ZStandardCompressor.java @@ -49,7 +49,7 @@ public class ZStandardCompressor implements Compressor { private int uncompressedDirectBufOff = 0, uncompressedDirectBufLen = 0; private boolean keepUncompressedBuf = false; private ByteBuffer compressedDirectBuf = null; - private boolean finish, finished; + private boolean finished; private long bytesRead = 0; private long bytesWritten = 0; @@ -180,7 +180,6 @@ public boolean needsInput() { @Override public void finish() { - finish = true; } @Override @@ -266,7 +265,6 @@ public long getBytesRead() { public void reset() { checkStream(); init(level, stream); - finish = false; finished = false; bytesRead = 0; bytesWritten = 0;