Lines Matching defs:zstream
32 z_stream zstream;
81 zstream.zalloc = NULL;
82 zstream.zfree = NULL;
83 zstream.opaque = NULL;
84 if (inflateInit(&zstream) != Z_OK) {
94 inflateEnd(&zstream);
100 last_out = zstream.total_out;
102 zstream.next_in = &buf_in[0];
103 zstream.avail_in = len;
104 zstream.next_out = &buf_out[0];
105 zstream.avail_out = 65536;
107 ret = inflate(&zstream, Z_SYNC_FLUSH);
110 inflateEnd(&zstream);
115 zstream.avail_in, zstream.total_in, zstream.avail_out,
116 zstream.total_out, zstream.total_out - last_out);
118 if (write(fd_out, &buf_out, zstream.total_out - last_out) <
119 zstream.total_out - last_out) {
121 inflateEnd(&zstream);
131 if (zstream.total_out != uncomp_len - 8) {
133 zstream.total_out, uncomp_len - 8);
135 buf_in[0] = (zstream.total_out + 8) & 0xff;
136 buf_in[1] = ((zstream.total_out + 8) >> 8) & 0xff;
137 buf_in[2] = ((zstream.total_out + 8) >> 16) & 0xff;
138 buf_in[3] = ((zstream.total_out + 8) >> 24) & 0xff;
143 inflateEnd(&zstream);
149 inflateEnd(&zstream);