History log of /libcore/luni/src/test/java/libcore/java/util/zip/InflaterTest.java
Revision Date Author Comments
b9f4eb77cf7c5937fcd33d839c749900112874bd 07-Jan-2011 Jesse Wilson <jessewilson@google.com> Don't short-circuit Inflater.inflate() on zero-length requests.

Change-Id: I2d207ee16dd432ba4211990da21a345f81375039
http://code.google.com/p/android/issues/detail?id=11755
aee3e4d2e0a2830fc2ef8e96a13796d012becab2 07-Dec-2010 Elliott Hughes <enh@google.com> Throw better exceptions if an Inflater or Deflater is used after calling end.

Bug: 3217912
Change-Id: I480c92d2f97b530f17b9b8daf2549d2f06384219
2d9c5fa8ce0182cd8c14736241b709fd50cab6f8 23-Nov-2010 Elliott Hughes <enh@google.com> Slight cleanup of java.util.zip code, plus a bug fix.

The key fix is switching to zstream's next_in and next_out fields (the
pointers into the input and output buffers) rather than relying on the
integer "accounting" fields. If turns out in the Z_NEED_DICT case that
the accounting goes slightly awry. (We shouldn't have been using the
accounting anyway, because we were silently coercing longs to ints.)
The new code is simpler, clearer, and doesn't need a special case for
Z_NEED_DICT at all.

I've also removed yet another hand-written UTF-8 encoder, made Inflater
throw ArrayIndexOutOfBoundsExceptions with useful detail messages (factored
out into Arrays so we can make this change more widely), and
rewritten the Inflater and Deflater documentation.

The unit test reproduces the problem (and tests as many other cases as
it can too). Critical for testing this bug is that we needed to limit
the size of the input buffer so that zlib has to ask us for more input.

Bug: 3220923
Change-Id: I39e5456620eaa7f75d12d885db279f009ee3e8ef