This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-compress.git
commit 6f007a3f43f5c2651eac994b8e64b268acbca7b2 Author: Gary Gregory <garydgreg...@gmail.com> AuthorDate: Sat Feb 17 11:16:15 2024 -0500 Preserve input argument For debugging --- .../java/org/apache/commons/compress/harmony/unpack200/Segment.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/main/java/org/apache/commons/compress/harmony/unpack200/Segment.java b/src/main/java/org/apache/commons/compress/harmony/unpack200/Segment.java index 00fbc0294..014db4938 100644 --- a/src/main/java/org/apache/commons/compress/harmony/unpack200/Segment.java +++ b/src/main/java/org/apache/commons/compress/harmony/unpack200/Segment.java @@ -483,10 +483,8 @@ public class Segment { /* * Package-private accessors for unpacking stages */ - void unpackRead(InputStream in) throws IOException, Pack200Exception { - if (!in.markSupported()) { - in = new BufferedInputStream(in); - } + void unpackRead(final InputStream inputStream) throws IOException, Pack200Exception { + final InputStream in = inputStream.markSupported() ? inputStream : new BufferedInputStream(inputStream); header = new SegmentHeader(this); header.read(in);