Lines Matching refs:zstream
524 struct z_stream_s zstream; in zlib_inflate() local
527 memset(&zstream, 0, sizeof(zstream)); in zlib_inflate()
529 zstream.next_in = (unsigned char *)compressed_data; in zlib_inflate()
530 zstream.avail_in = compressed_len; in zlib_inflate()
532 if (inflateInit(&zstream) != Z_OK) in zlib_inflate()
536 zstream.next_out = out; in zlib_inflate()
537 zstream.avail_out = 4096; in zlib_inflate()
540 switch (inflate(&zstream, Z_SYNC_FLUSH)) { in zlib_inflate()
546 inflateEnd(&zstream); in zlib_inflate()
550 if (zstream.avail_out) in zlib_inflate()
553 out = realloc(out, 2*zstream.total_out); in zlib_inflate()
555 inflateEnd(&zstream); in zlib_inflate()
559 zstream.next_out = (unsigned char *)out + zstream.total_out; in zlib_inflate()
560 zstream.avail_out = zstream.total_out; in zlib_inflate()
563 inflateEnd(&zstream); in zlib_inflate()
565 return zstream.total_out; in zlib_inflate()