diff options
author | Eugene Kliuchnikov <eustas@google.com> | 2018-03-02 15:49:58 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-03-02 15:49:58 +0100 |
commit | 533843e3546cd24c8344eaa899c6b0b681c8d222 (patch) | |
tree | 13625b3d6b0e53b23814c6e678d4ed853c73abff /java/org | |
parent | 35e69fc7cf9421ab04ffc9d52cb36d07fa12984a (diff) | |
download | brotli-533843e3546cd24c8344eaa899c6b0b681c8d222.zip brotli-533843e3546cd24c8344eaa899c6b0b681c8d222.tar.gz brotli-533843e3546cd24c8344eaa899c6b0b681c8d222.tar.bz2 |
Update (#643)v1.0.3
Update
* make the zopflification aware of `NDIRECT`, `NPOSTFIX`
(better compression in `font` mode)
* add small and simple decoder tool
* fix typo
* Java: wrapper: make decoder channel more async-friendly
Ramp up version to 1.0.3 / 1.0.3
Diffstat (limited to 'java/org')
-rw-r--r-- | java/org/brotli/wrapper/dec/BrotliDecoderChannel.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/java/org/brotli/wrapper/dec/BrotliDecoderChannel.java b/java/org/brotli/wrapper/dec/BrotliDecoderChannel.java index c9a752a..6dfe8f2 100644 --- a/java/org/brotli/wrapper/dec/BrotliDecoderChannel.java +++ b/java/org/brotli/wrapper/dec/BrotliDecoderChannel.java @@ -58,8 +58,8 @@ public class BrotliDecoderChannel extends Decoder implements ReadableByteChannel int result = 0; while (dst.hasRemaining()) { int outputSize = decode(); - if (outputSize == -1) { - return result == 0 ? -1 : result; + if (outputSize <= 0) { + return result == 0 ? outputSize : result; } result += consume(dst); } |