Fix checkstyle problems
This commit is contained in:
parent
b22ebbe430
commit
5d99d57cab
@ -112,4 +112,8 @@ final class Adler32 {
|
||||
}
|
||||
return s2 << 16 | s1;
|
||||
}
|
||||
|
||||
private Adler32() {
|
||||
// Utility Class
|
||||
}
|
||||
}
|
||||
|
@ -92,4 +92,8 @@ final class CRC32 {
|
||||
crc32 ^= 0xffffffff;
|
||||
return crc32;
|
||||
}
|
||||
|
||||
private CRC32() {
|
||||
// Utility Class
|
||||
}
|
||||
}
|
||||
|
@ -514,7 +514,7 @@ final class Deflate {
|
||||
|
||||
private void send_code(int c, short[] tree) {
|
||||
int c2 = c * 2;
|
||||
send_bits((tree[c2] & 0xffff), (tree[c2 + 1] & 0xffff));
|
||||
send_bits(tree[c2] & 0xffff, tree[c2 + 1] & 0xffff);
|
||||
}
|
||||
|
||||
private void send_bits(int value, int length) {
|
||||
|
@ -124,16 +124,15 @@ final class InfBlocks {
|
||||
int m; // bytes to end of window or read pointer
|
||||
|
||||
// copy input/output information to locals (UPDATE macro restores)
|
||||
{
|
||||
|
||||
p = z.next_in_index;
|
||||
n = z.avail_in;
|
||||
b = bitb;
|
||||
k = bitk;
|
||||
}
|
||||
{
|
||||
|
||||
q = write;
|
||||
m = q < read? read - q - 1 : end - q;
|
||||
}
|
||||
|
||||
|
||||
// process input based on current state
|
||||
while (true) {
|
||||
@ -161,20 +160,17 @@ final class InfBlocks {
|
||||
|
||||
switch (t >>> 1) {
|
||||
case 0: // stored
|
||||
{
|
||||
|
||||
b >>>= 3;
|
||||
k -= 3;
|
||||
}
|
||||
|
||||
t = k & 7; // go to byte boundary
|
||||
|
||||
{
|
||||
b >>>= t;
|
||||
k -= t;
|
||||
}
|
||||
mode = LENS; // get length of stored block
|
||||
break;
|
||||
case 1: // fixed
|
||||
{
|
||||
int[] bl = new int[1];
|
||||
int[] bd = new int[1];
|
||||
int[][] tl = new int[1][];
|
||||
@ -182,30 +178,24 @@ final class InfBlocks {
|
||||
|
||||
InfTree.inflate_trees_fixed(bl, bd, tl, td);
|
||||
codes.init(bl[0], bd[0], tl[0], 0, td[0], 0);
|
||||
}
|
||||
|
||||
{
|
||||
b >>>= 3;
|
||||
k -= 3;
|
||||
}
|
||||
|
||||
mode = CODES;
|
||||
break;
|
||||
case 2: // dynamic
|
||||
|
||||
{
|
||||
b >>>= 3;
|
||||
k -= 3;
|
||||
}
|
||||
|
||||
mode = TABLE;
|
||||
break;
|
||||
case 3: // illegal
|
||||
|
||||
{
|
||||
b >>>= 3;
|
||||
k -= 3;
|
||||
}
|
||||
|
||||
mode = BAD;
|
||||
z.msg = "invalid block type";
|
||||
r = JZlib.Z_DATA_ERROR;
|
||||
@ -352,10 +342,9 @@ final class InfBlocks {
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
|
||||
b >>>= 14;
|
||||
k -= 14;
|
||||
}
|
||||
|
||||
index = 0;
|
||||
mode = BTREE;
|
||||
@ -380,10 +369,9 @@ final class InfBlocks {
|
||||
|
||||
blens[border[index ++]] = b & 7;
|
||||
|
||||
{
|
||||
b >>>= 3;
|
||||
k -= 3;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
while (index < 19) {
|
||||
@ -505,7 +493,7 @@ final class InfBlocks {
|
||||
}
|
||||
|
||||
tb[0] = -1;
|
||||
{
|
||||
|
||||
int[] bl = new int[1];
|
||||
int[] bd = new int[1];
|
||||
int[] tl = new int[1];
|
||||
@ -534,7 +522,7 @@ final class InfBlocks {
|
||||
return inflate_flush(z, r);
|
||||
}
|
||||
codes.init(bl[0], bd[0], hufts, tl[0], hufts, td[0]);
|
||||
}
|
||||
|
||||
mode = CODES;
|
||||
case CODES:
|
||||
bitb = b;
|
||||
|
@ -71,7 +71,7 @@ final class InfCodes {
|
||||
// mode dependent information
|
||||
private int len;
|
||||
private int[] tree; // pointer into tree
|
||||
private int tree_index = 0;
|
||||
private int tree_index;
|
||||
private int need; // bits needed
|
||||
private int lit;
|
||||
// if EXT or COPY, where and how much
|
||||
|
@ -105,4 +105,8 @@ public final class JZlib {
|
||||
enum WrapperType {
|
||||
NONE, ZLIB, GZIP, ZLIB_OR_NONE
|
||||
}
|
||||
|
||||
private JZlib() {
|
||||
// Utility class
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,21 @@
|
||||
/*
|
||||
* Copyright 2011 The Netty Project
|
||||
*
|
||||
* The Netty Project licenses this file to you under the Apache License,
|
||||
* version 2.0 (the "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at:
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
|
||||
/**
|
||||
* <em>Internal-use-only</em> utilities which is not allowed to be used
|
||||
* outside Netty.
|
||||
*/
|
||||
package io.netty.util.internal.jzlib;
|
Loading…
Reference in New Issue
Block a user