From 8f2b4c5f4f8a977c4b07393e3156b1c02d1085fc Mon Sep 17 00:00:00 2001 From: Stefan Bodewig Date: Mon, 21 May 2012 12:28:19 +0000 Subject: [PATCH] merged one hunk the wrong way around, allowableblocksize should remain final git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@1340990 13f79535-47bb-0310-9956-ffa450edef68 --- src/main/org/apache/tools/bzip2/CBZip2OutputStream.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/org/apache/tools/bzip2/CBZip2OutputStream.java b/src/main/org/apache/tools/bzip2/CBZip2OutputStream.java index cbdd87a01..cfee7fcfd 100644 --- a/src/main/org/apache/tools/bzip2/CBZip2OutputStream.java +++ b/src/main/org/apache/tools/bzip2/CBZip2OutputStream.java @@ -547,7 +547,7 @@ public class CBZip2OutputStream extends OutputStream private int blockCRC; private int combinedCRC; - private int allowableBlockSize; + private final int allowableBlockSize; /** * All memory intensive stuff. @@ -635,6 +635,9 @@ public class CBZip2OutputStream extends OutputStream this.blockSize100k = blockSize; this.out = out; + + /* 20 is just a paranoia constant */ + this.allowableBlockSize = (this.blockSize100k * BZip2Constants.baseBlockSize) - 20; init(); } @@ -788,9 +791,6 @@ public class CBZip2OutputStream extends OutputStream for (int i = 256; --i >= 0;) { inUse[i] = false; } - - /* 20 is just a paranoia constant */ - this.allowableBlockSize = (this.blockSize100k * BZip2Constants.baseBlockSize) - 20; } private void endBlock() throws IOException {