Skip to content

Commit

Permalink
move to 0.9.2 on LZF
Browse files Browse the repository at this point in the history
  • Loading branch information
kimchy committed Jan 4, 2012
1 parent d6436f3 commit b8c5687
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ public static int calculateUncompressedSize(byte[] data, int ptr, int length) th
++blockNr;
}
// one more sanity check:
if (ptr != data.length) {
if (ptr != end) {
throw new IOException("Corrupt input data: block #" + blockNr + " extends " + (data.length - ptr) + " beyond end of input");
}
return uncompressedSize;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,19 @@ public static byte[] decode(final byte[] inputBuffer) throws IOException {
return decode(inputBuffer, 0, inputBuffer.length);
}

public static byte[] decode(final byte[] inputBuffer, int inputPtr, int inputLen) throws IOException {
return ChunkDecoderFactory.optimalInstance().decode(inputBuffer);
public static byte[] decode(final byte[] inputBuffer, int offset, int length) throws IOException {
return ChunkDecoderFactory.optimalInstance().decode(inputBuffer, offset, length);
}

public static int decode(final byte[] inputBuffer, final byte[] targetBuffer) throws IOException {
return decode(inputBuffer, 0, inputBuffer.length, targetBuffer);
}

public static int decode(final byte[] sourceBuffer, int inPtr, int inLength, final byte[] targetBuffer) throws IOException {
return ChunkDecoderFactory.optimalInstance().decode(sourceBuffer, inPtr, inLength, targetBuffer);
public static int decode(final byte[] sourceBuffer, int offset, int length, final byte[] targetBuffer) throws IOException {
return ChunkDecoderFactory.optimalInstance().decode(sourceBuffer, offset, length, targetBuffer);
}

public static int calculateUncompressedSize(byte[] data, int ptr, int length) throws IOException {
return ChunkDecoder.calculateUncompressedSize(data, ptr, length);
public static int calculateUncompressedSize(byte[] data, int offset, int length) throws IOException {
return ChunkDecoder.calculateUncompressedSize(data, offset, length);
}
}

0 comments on commit b8c5687

Please sign in to comment.