Lines Matching refs:strm
49 struct z_stream_s *strm; in __gunzip() local
76 strm = malloc(sizeof(*strm)); in __gunzip()
77 if (strm == NULL) { in __gunzip()
82 strm->workspace = malloc(flush ? zlib_inflate_workspacesize() : in __gunzip()
89 if (strm->workspace == NULL) { in __gunzip()
112 strm->next_in = zbuf + 10; in __gunzip()
113 strm->avail_in = len - 10; in __gunzip()
122 if (strm->avail_in == 0) { in __gunzip()
126 --strm->avail_in; in __gunzip()
127 } while (*strm->next_in++); in __gunzip()
130 strm->next_out = out_buf; in __gunzip()
131 strm->avail_out = out_len; in __gunzip()
133 rc = zlib_inflateInit2(strm, -MAX_WBITS); in __gunzip()
139 WS(strm)->inflate_state.wsize = 0; in __gunzip()
140 WS(strm)->inflate_state.window = NULL; in __gunzip()
145 if (strm->avail_in == 0) { in __gunzip()
153 strm->next_in = zbuf; in __gunzip()
154 strm->avail_in = len; in __gunzip()
156 rc = zlib_inflate(strm, 0); in __gunzip()
159 if (flush && strm->next_out > out_buf) { in __gunzip()
160 long l = strm->next_out - out_buf; in __gunzip()
166 strm->next_out = out_buf; in __gunzip()
167 strm->avail_out = out_len; in __gunzip()
180 zlib_inflateEnd(strm); in __gunzip()
183 *pos = strm->next_in - zbuf+8; in __gunzip()
186 free(strm->workspace); in __gunzip()
188 free(strm); in __gunzip()