diff options
-rw-r--r-- | java/src/com/tigervnc/rdr/ZlibInStream.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/java/src/com/tigervnc/rdr/ZlibInStream.java b/java/src/com/tigervnc/rdr/ZlibInStream.java index 439ddfe2..62c45bd8 100644 --- a/java/src/com/tigervnc/rdr/ZlibInStream.java +++ b/java/src/com/tigervnc/rdr/ZlibInStream.java @@ -33,6 +33,7 @@ public class ZlibInStream extends InStream { b = new byte[bufSize]; bytesIn = offset = 0; zs = new ZStream(); + zs.next_in = null; zs.next_in_index = 0; zs.avail_in = 0; if (zs.inflateInit() != JZlib.Z_OK) { @@ -112,6 +113,7 @@ public class ZlibInStream extends InStream { int n = underlying.check(1, 1, wait); if (n == 0) return false; zs.next_in = underlying.getbuf(); + zs.next_in_index = underlying.getptr(); zs.avail_in = underlying.getend() - underlying.getptr(); if (zs.avail_in > bytesIn) zs.avail_in = bytesIn; |