Lines Matching refs:strm

61912   this.strm = new ZStream();
61913 this.strm.avail_out = 0;
61914 …var status = zlib_deflate.deflateInit2(this.strm, opt.level, opt.method, opt.windowBits, opt.memLe…
61921 zlib_deflate.deflateSetHeader(this.strm, opt.header);
61936 status = zlib_deflate.deflateSetDictionary(this.strm, dict);
61977 var strm = this.strm;
61990 strm.input = strings.string2buf(data);
61992 strm.input = new Uint8Array(data);
61994 strm.input = data;
61997 strm.next_in = 0;
61998 strm.avail_in = strm.input.length;
62001 if (strm.avail_out === 0) {
62002 strm.output = new utils.Buf8(chunkSize);
62003 strm.next_out = 0;
62004 strm.avail_out = chunkSize;
62007 status = zlib_deflate.deflate(strm, _mode);
62016 …if (strm.avail_out === 0 || strm.avail_in === 0 && (_mode === Z_FINISH || _mode === Z_SYNC_FLUSH))…
62018 this.onData(strings.buf2binstring(utils.shrinkBuf(strm.output, strm.next_out)));
62020 this.onData(utils.shrinkBuf(strm.output, strm.next_out));
62023 …} while ((strm.avail_in > 0 || strm.avail_out === 0) && status !== Z_STREAM_END); // Finalize on t…
62027 status = zlib_deflate.deflateEnd(this.strm);
62036 strm.avail_out = 0;
62080 this.msg = this.strm.msg;
62302 this.strm = new ZStream();
62303 this.strm.avail_out = 0;
62304 var status = zlib_inflate.inflateInit2(this.strm, opt.windowBits);
62311 zlib_inflate.inflateGetHeader(this.strm, this.header); // Setup dictionary
62323 status = zlib_inflate.inflateSetDictionary(this.strm, opt.dictionary);
62362 var strm = this.strm;
62381 strm.input = strings.binstring2buf(data);
62383 strm.input = new Uint8Array(data);
62385 strm.input = data;
62388 strm.next_in = 0;
62389 strm.avail_in = strm.input.length;
62392 if (strm.avail_out === 0) {
62393 strm.output = new utils.Buf8(chunkSize);
62394 strm.next_out = 0;
62395 strm.avail_out = chunkSize;
62398 status = zlib_inflate.inflate(strm, c.Z_NO_FLUSH);
62402 status = zlib_inflate.inflateSetDictionary(this.strm, dictionary);
62416 if (strm.next_out) {
62417 …if (strm.avail_out === 0 || status === c.Z_STREAM_END || strm.avail_in === 0 && (_mode === c.Z_FIN…
62419 next_out_utf8 = strings.utf8border(strm.output, strm.next_out);
62420 tail = strm.next_out - next_out_utf8;
62421 utf8str = strings.buf2string(strm.output, next_out_utf8); // move tail
62423 strm.next_out = tail;
62424 strm.avail_out = chunkSize - tail;
62427 utils.arraySet(strm.output, strm.output, next_out_utf8, tail, 0);
62432 this.onData(utils.shrinkBuf(strm.output, strm.next_out));
62444 if (strm.avail_in === 0 && strm.avail_out === 0) {
62447 } while ((strm.avail_in > 0 || strm.avail_out === 0) && status !== c.Z_STREAM_END);
62455 status = zlib_inflate.inflateEnd(this.strm);
62464 strm.avail_out = 0;
62510 this.msg = this.strm.msg;
63235 function err(strm, errorCode) {
63236 strm.msg = msg[errorCode];
63259 function flush_pending(strm) {
63260 var s = strm.state; //_tr_flush_bits(s);
63264 if (len > strm.avail_out) {
63265 len = strm.avail_out;
63272 utils.arraySet(strm.output, s.pending_buf, s.pending_out, len, strm.next_out);
63273 strm.next_out += len;
63275 strm.total_out += len;
63276 strm.avail_out -= len;
63288 flush_pending(s.strm);
63316 function read_buf(strm, buf, start, size) {
63317 var len = strm.avail_in;
63327 strm.avail_in -= len; // zmemcpy(buf, strm->next_in, len);
63329 utils.arraySet(buf, strm.input, strm.next_in, len, start);
63331 if (strm.state.wrap === 1) {
63332 strm.adler = adler32(strm.adler, buf, len, start);
63333 } else if (strm.state.wrap === 2) {
63334 strm.adler = crc32(strm.adler, buf, len, start);
63337 strm.next_in += len;
63338 strm.total_in += len;
63534 if (s.strm.avail_in === 0) {
63551 n = read_buf(s.strm, s.window, s.strstart + s.lookahead, more);
63581 } while (s.lookahead < MIN_LOOKAHEAD && s.strm.avail_in !== 0);
63681 if (s.strm.avail_out === 0) {
63696 if (s.strm.avail_out === 0) {
63710 if (s.strm.avail_out === 0) {
63723 if (s.strm.avail_out === 0) {
63858 if (s.strm.avail_out === 0) {
63872 if (s.strm.avail_out === 0) {
63885 if (s.strm.avail_out === 0) {
64016 if (s.strm.avail_out === 0) {
64041 if (s.strm.avail_out === 0) {
64069 if (s.strm.avail_out === 0) {
64082 if (s.strm.avail_out === 0) {
64177 if (s.strm.avail_out === 0) {
64191 if (s.strm.avail_out === 0) {
64204 if (s.strm.avail_out === 0) {
64252 if (s.strm.avail_out === 0) {
64266 if (s.strm.avail_out === 0) {
64279 if (s.strm.avail_out === 0) {
64354 this.strm = null;
64609 function deflateResetKeep(strm) {
64612 if (!strm || !strm.state) {
64613 return err(strm, Z_STREAM_ERROR);
64616 strm.total_in = strm.total_out = 0;
64617 strm.data_type = Z_UNKNOWN;
64618 s = strm.state;
64628 strm.adler = s.wrap === 2 ? 0 // crc32(0, Z_NULL, 0)
64638 function deflateReset(strm) {
64639 var ret = deflateResetKeep(strm);
64642 lm_init(strm.state);
64648 function deflateSetHeader(strm, head) {
64649 if (!strm || !strm.state) {
64653 if (strm.state.wrap !== 2) {
64657 strm.state.gzhead = head;
64661 function deflateInit2(strm, level, method, windowBits, memLevel, strategy) {
64662 if (!strm) {
64685 return err(strm, Z_STREAM_ERROR);
64695 strm.state = s;
64696 s.strm = strm;
64726 return deflateReset(strm);
64729 function deflateInit(strm, level) {
64730 return deflateInit2(strm, level, Z_DEFLATED, MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY);
64733 function deflate(strm, flush) {
64737 if (!strm || !strm.state || flush > Z_BLOCK || flush < 0) {
64738 return strm ? err(strm, Z_STREAM_ERROR) : Z_STREAM_ERROR;
64741 s = strm.state;
64743 …if (!strm.output || !strm.input && strm.avail_in !== 0 || s.status === FINISH_STATE && flush !== Z…
64744 return err(strm, strm.avail_out === 0 ? Z_BUF_ERROR : Z_STREAM_ERROR);
64747 s.strm = strm;
64757 strm.adler = 0; //crc32(0L, Z_NULL, 0);
64788 strm.adler = crc32(strm.adler, s.pending_buf, s.pending, 0);
64821 putShortMSB(s, strm.adler >>> 16);
64822 putShortMSB(s, strm.adler & 0xffff);
64825 strm.adler = 1; // adler32(0L, Z_NULL, 0);
64840 strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);
64843 flush_pending(strm);
64856 strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);
64879 strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);
64882 flush_pending(strm);
64902 strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);
64925 strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);
64928 flush_pending(strm);
64948 strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);
64962 flush_pending(strm);
64966 put_byte(s, strm.adler & 0xff);
64967 put_byte(s, strm.adler >> 8 & 0xff);
64968 strm.adler = 0; //crc32(0L, Z_NULL, 0);
64981 flush_pending(strm);
64983 if (strm.avail_out === 0) {
64998 } else if (strm.avail_in === 0 && rank(flush) <= rank(old_flush) && flush !== Z_FINISH) {
64999 return err(strm, Z_BUF_ERROR);
65004 if (s.status === FINISH_STATE && strm.avail_in !== 0) {
65005 return err(strm, Z_BUF_ERROR);
65011 …if (strm.avail_in !== 0 || s.lookahead !== 0 || flush !== Z_NO_FLUSH && s.status !== FINISH_STATE)…
65019 if (strm.avail_out === 0) {
65059 flush_pending(strm);
65061 if (strm.avail_out === 0) {
65083 put_byte(s, strm.adler & 0xff);
65084 put_byte(s, strm.adler >> 8 & 0xff);
65085 put_byte(s, strm.adler >> 16 & 0xff);
65086 put_byte(s, strm.adler >> 24 & 0xff);
65087 put_byte(s, strm.total_in & 0xff);
65088 put_byte(s, strm.total_in >> 8 & 0xff);
65089 put_byte(s, strm.total_in >> 16 & 0xff);
65090 put_byte(s, strm.total_in >> 24 & 0xff);
65092 putShortMSB(s, strm.adler >>> 16);
65093 putShortMSB(s, strm.adler & 0xffff);
65096 flush_pending(strm);
65110 function deflateEnd(strm) {
65113 if (!strm
65115 || !strm.state
65121 status = strm.state.status;
65124 return err(strm, Z_STREAM_ERROR);
65127 strm.state = null;
65128 return status === BUSY_STATE ? err(strm, Z_DATA_ERROR) : Z_OK;
65136 function deflateSetDictionary(strm, dictionary) {
65146 if (!strm
65148 || !strm.state
65154 s = strm.state;
65165 strm.adler = adler32(strm.adler, dictionary, dictLength, 0);
65196 avail = strm.avail_in;
65197 next = strm.next_in;
65198 input = strm.input;
65199 strm.avail_in = dictLength;
65200 strm.next_in = 0;
65201 strm.input = dictionary;
65227 strm.next_in = next;
65228 strm.input = input;
65229 strm.avail_in = avail;
65384 module.exports = function inflate_fast(strm, start) {
65462 state = strm.state; //here = state.here;
65464 _in = strm.next_in;
65465 input = strm.input;
65466 last = _in + (strm.avail_in - 5);
65467 _out = strm.next_out;
65468 output = strm.output;
65469 beg = _out - (start - strm.avail_out);
65470 end = _out + (strm.avail_out - 257); //#ifdef INFLATE_STRICT
65577 strm.msg = 'invalid distance too far back';
65596 strm.msg = 'invalid distance too far back';
65734 strm.msg = 'invalid distance code';
65753 strm.msg = 'invalid literal/length code';
65770 strm.next_in = _in;
65771 strm.next_out = _out;
65772 strm.avail_in = _in < last ? 5 + (last - _in) : 5 - (_in - last);
65773 strm.avail_out = _out < end ? 257 + (end - _out) : 257 - (_out - end);
66081 function inflateResetKeep(strm) {
66084 if (!strm || !strm.state) {
66088 state = strm.state;
66089 strm.total_in = strm.total_out = state.total = 0;
66090 strm.msg = '';
66095 strm.adler = state.wrap & 1;
66116 function inflateReset(strm) {
66119 if (!strm || !strm.state) {
66123 state = strm.state;
66127 return inflateResetKeep(strm);
66130 function inflateReset2(strm, windowBits) {
66135 if (!strm || !strm.state) {
66139 state = strm.state;
66167 return inflateReset(strm);
66170 function inflateInit2(strm, windowBits) {
66174 if (!strm) {
66182 strm.state = state;
66186 ret = inflateReset2(strm, windowBits);
66189 strm.state = null
66197 function inflateInit(strm) {
66198 return inflateInit2(strm, DEF_WBITS);
66281 function updatewindow(strm, src, end, copy) {
66283 var state = strm.state;
66331 function inflate(strm, flush) {
66385 if (!strm || !strm.state || !strm.output || !strm.input && strm.avail_in !== 0) {
66389 state = strm.state;
66398 put = strm.next_out;
66399 output = strm.output;
66400 left = strm.avail_out;
66401 next = strm.next_in;
66402 input = strm.input;
66403 have = strm.avail_in;
66462 strm.msg = 'incorrect header check';
66470 strm.msg = 'unknown compression method';
66486 strm.msg = 'invalid window size';
66493 strm.adler = state.check = 1
66519 strm.msg = 'unknown compression method';
66525 strm.msg = 'unknown header flags set';
66792 strm.msg = 'header crc mismatch';
66807 strm.adler = state.check = 0;
66824 strm.adler = state.check = zswap32(hold); //=== INITBITS();
66836 strm.next_out = put;
66837 strm.avail_out = left;
66838 strm.next_in = next;
66839 strm.avail_in = have;
66846 strm.adler = state.check = 1
66924 strm.msg = 'invalid block type';
66952 strm.msg = 'invalid stored block lengths';
67044 strm.msg = 'too many length or distance symbols';
67094 strm.msg = 'invalid code lengths set';
67156 strm.msg = 'invalid bit length repeat';
67220 strm.msg = 'invalid bit length repeat';
67240 strm.msg = 'invalid code -- missing end-of-block';
67259 strm.msg = 'invalid literal/lengths set';
67277 strm.msg = 'invalid distances set';
67299 strm.next_out = put;
67300 strm.avail_out = left;
67301 strm.next_in = next;
67302 strm.avail_in = have;
67306 inflate_fast(strm, _out); //--- LOAD() ---
67308 put = strm.next_out;
67309 output = strm.output;
67310 left = strm.avail_out;
67311 next = strm.next_in;
67312 input = strm.input;
67313 have = strm.avail_in;
67405 strm.msg = 'invalid literal/length code';
67511 strm.msg = 'invalid distance code';
67550 strm.msg = 'invalid distance too far back';
67574 strm.msg = 'invalid distance too far back';
67657 strm.total_out += _out;
67661 strm.adler = state.check =
67669 strm.msg = 'incorrect data check';
67699 strm.msg = 'incorrect length check';
67742 strm.next_out = put;
67743 strm.avail_out = left;
67744 strm.next_in = next;
67745 strm.avail_in = have;
67749 …if (state.wsize || _out !== strm.avail_out && state.mode < BAD && (state.mode < CHECK || flush !==…
67750 if (updatewindow(strm, strm.output, strm.next_out, _out - strm.avail_out)) {
67756 _in -= strm.avail_in;
67757 _out -= strm.avail_out;
67758 strm.total_in += _in;
67759 strm.total_out += _out;
67763 strm.adler = state.check =
67765 …ate.flags ? crc32(state.check, output, _out, strm.next_out - _out) : adler32(state.check, output, …
67768strm.data_type = state.bits + (state.last ? 64 : 0) + (state.mode === TYPE ? 128 : 0) + (state.mod…
67777 function inflateEnd(strm) {
67778 if (!strm || !strm.state
67784 var state = strm.state;
67790 strm.state = null;
67794 function inflateGetHeader(strm, head) {
67798 if (!strm || !strm.state) {
67802 state = strm.state;
67815 function inflateSetDictionary(strm, dictionary) {
67822 if (!strm
67824 || !strm.state
67830 state = strm.state;
67854 ret = updatewindow(strm, dictionary, dictLength, dictLength);
69736 if (s.strm.data_type === Z_UNKNOWN) {
69737 s.strm.data_type = detect_data_type(s);