Skip to content

Commit b0347d8

Browse files
committed
arrange input buffer
1 parent 580d9c5 commit b0347d8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/isal/igzip_lib.pyx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ cdef class IgzipDecompressor:
266266
cdef inflate_state stream
267267
cdef unsigned char * input_buffer
268268
cdef size_t input_buffer_size
269-
cdef size_t avail_in_real
269+
cdef Py_ssize_t avail_in_real
270270

271271
def __cinit__(self,
272272
flag=ISAL_DEFLATE,
@@ -310,8 +310,8 @@ cdef class IgzipDecompressor:
310310
raise MemoryError("Unsufficient memory for buffer allocation")
311311
elif obuflen == -2:
312312
break
313+
arrange_input_buffer(&self.stream, &self.avail_in_real)
313314
err = isal_inflate(&self.stream)
314-
data_size = self.stream.next_out - obuf
315315
if err != ISAL_DECOMP_OK:
316316
check_isal_inflate_rc(err)
317317
if self.stream.block_state == ISAL_BLOCK_FINISH:

0 commit comments

Comments
 (0)