Artifact d82cce085111a3e629a43629b442847efb41f10e:
0000: 2f 2a 20 69 6e 66 62 6c 6f 63 6b 2e 68 20 2d 2d /* infblock.h --
0010: 20 68 65 61 64 65 72 20 74 6f 20 75 73 65 20 69 header to use i
0020: 6e 66 62 6c 6f 63 6b 2e 63 0a 20 2a 20 43 6f 70 nfblock.c. * Cop
0030: 79 72 69 67 68 74 20 28 43 29 20 31 39 39 35 2d yright (C) 1995-
0040: 31 39 39 38 20 4d 61 72 6b 20 41 64 6c 65 72 0a 1998 Mark Adler.
0050: 20 2a 20 46 6f 72 20 63 6f 6e 64 69 74 69 6f 6e * For condition
0060: 73 20 6f 66 20 64 69 73 74 72 69 62 75 74 69 6f s of distributio
0070: 6e 20 61 6e 64 20 75 73 65 2c 20 73 65 65 20 63 n and use, see c
0080: 6f 70 79 72 69 67 68 74 20 6e 6f 74 69 63 65 20 opyright notice
0090: 69 6e 20 7a 6c 69 62 2e 68 20 0a 20 2a 2f 0a 0a in zlib.h . */..
00a0: 2f 2a 20 57 41 52 4e 49 4e 47 3a 20 74 68 69 73 /* WARNING: this
00b0: 20 66 69 6c 65 20 73 68 6f 75 6c 64 20 2a 6e 6f file should *no
00c0: 74 2a 20 62 65 20 75 73 65 64 20 62 79 20 61 70 t* be used by ap
00d0: 70 6c 69 63 61 74 69 6f 6e 73 2e 20 49 74 20 69 plications. It i
00e0: 73 0a 20 20 20 70 61 72 74 20 6f 66 20 74 68 65 s. part of the
00f0: 20 69 6d 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 20 implementation
0100: 6f 66 20 74 68 65 20 63 6f 6d 70 72 65 73 73 69 of the compressi
0110: 6f 6e 20 6c 69 62 72 61 72 79 20 61 6e 64 20 69 on library and i
0120: 73 0a 20 20 20 73 75 62 6a 65 63 74 20 74 6f 20 s. subject to
0130: 63 68 61 6e 67 65 2e 20 41 70 70 6c 69 63 61 74 change. Applicat
0140: 69 6f 6e 73 20 73 68 6f 75 6c 64 20 6f 6e 6c 79 ions should only
0150: 20 75 73 65 20 7a 6c 69 62 2e 68 2e 0a 20 2a 2f use zlib.h.. */
0160: 0a 0a 73 74 72 75 63 74 20 69 6e 66 6c 61 74 65 ..struct inflate
0170: 5f 62 6c 6f 63 6b 73 5f 73 74 61 74 65 3b 0a 74 _blocks_state;.t
0180: 79 70 65 64 65 66 20 73 74 72 75 63 74 20 69 6e ypedef struct in
0190: 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 5f 73 74 61 flate_blocks_sta
01a0: 74 65 20 46 41 52 20 69 6e 66 6c 61 74 65 5f 62 te FAR inflate_b
01b0: 6c 6f 63 6b 73 5f 73 74 61 74 65 66 3b 0a 0a 65 locks_statef;..e
01c0: 78 74 65 72 6e 20 69 6e 66 6c 61 74 65 5f 62 6c xtern inflate_bl
01d0: 6f 63 6b 73 5f 73 74 61 74 65 66 20 2a 20 69 6e ocks_statef * in
01e0: 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 5f 6e 65 77 flate_blocks_new
01f0: 20 4f 46 28 28 0a 20 20 20 20 7a 5f 73 74 72 65 OF((. z_stre
0200: 61 6d 70 20 7a 2c 0a 20 20 20 20 63 68 65 63 6b amp z,. check
0210: 5f 66 75 6e 63 20 63 2c 20 20 20 20 20 20 20 20 _func c,
0220: 20 20 20 20 20 20 20 2f 2a 20 63 68 65 63 6b 20 /* check
0230: 66 75 6e 63 74 69 6f 6e 20 2a 2f 0a 20 20 20 20 function */.
0240: 75 49 6e 74 20 77 29 29 3b 20 20 20 20 20 20 20 uInt w));
0250: 20 20 20 20 20 20 20 20 20 20 20 20 2f 2a 20 77 /* w
0260: 69 6e 64 6f 77 20 73 69 7a 65 20 2a 2f 0a 0a 65 indow size */..e
0270: 78 74 65 72 6e 20 69 6e 74 20 69 6e 66 6c 61 74 xtern int inflat
0280: 65 5f 62 6c 6f 63 6b 73 20 4f 46 28 28 0a 20 20 e_blocks OF((.
0290: 20 20 69 6e 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 inflate_blocks
02a0: 5f 73 74 61 74 65 66 20 2a 2c 0a 20 20 20 20 7a _statef *,. z
02b0: 5f 73 74 72 65 61 6d 70 20 2c 0a 20 20 20 20 69 _streamp ,. i
02c0: 6e 74 29 29 3b 20 20 20 20 20 20 20 20 20 20 20 nt));
02d0: 20 20 20 20 20 20 20 20 20 20 20 2f 2a 20 69 6e /* in
02e0: 69 74 69 61 6c 20 72 65 74 75 72 6e 20 63 6f 64 itial return cod
02f0: 65 20 2a 2f 0a 0a 65 78 74 65 72 6e 20 76 6f 69 e */..extern voi
0300: 64 20 69 6e 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 d inflate_blocks
0310: 5f 72 65 73 65 74 20 4f 46 28 28 0a 20 20 20 20 _reset OF((.
0320: 69 6e 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 5f 73 inflate_blocks_s
0330: 74 61 74 65 66 20 2a 2c 0a 20 20 20 20 7a 5f 73 tatef *,. z_s
0340: 74 72 65 61 6d 70 20 2c 0a 20 20 20 20 75 4c 6f treamp ,. uLo
0350: 6e 67 66 20 2a 29 29 3b 20 20 20 20 20 20 20 20 ngf *));
0360: 20 20 20 20 20 20 20 20 20 20 2f 2a 20 63 68 65 /* che
0370: 63 6b 20 76 61 6c 75 65 20 6f 6e 20 6f 75 74 70 ck value on outp
0380: 75 74 20 2a 2f 0a 0a 65 78 74 65 72 6e 20 69 6e ut */..extern in
0390: 74 20 69 6e 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 t inflate_blocks
03a0: 5f 66 72 65 65 20 4f 46 28 28 0a 20 20 20 20 69 _free OF((. i
03b0: 6e 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 5f 73 74 nflate_blocks_st
03c0: 61 74 65 66 20 2a 2c 0a 20 20 20 20 7a 5f 73 74 atef *,. z_st
03d0: 72 65 61 6d 70 29 29 3b 0a 0a 65 78 74 65 72 6e reamp));..extern
03e0: 20 76 6f 69 64 20 69 6e 66 6c 61 74 65 5f 73 65 void inflate_se
03f0: 74 5f 64 69 63 74 69 6f 6e 61 72 79 20 4f 46 28 t_dictionary OF(
0400: 28 0a 20 20 20 20 69 6e 66 6c 61 74 65 5f 62 6c (. inflate_bl
0410: 6f 63 6b 73 5f 73 74 61 74 65 66 20 2a 73 2c 0a ocks_statef *s,.
0420: 20 20 20 20 63 6f 6e 73 74 20 42 79 74 65 66 20 const Bytef
0430: 2a 64 2c 20 20 2f 2a 20 64 69 63 74 69 6f 6e 61 *d, /* dictiona
0440: 72 79 20 2a 2f 0a 20 20 20 20 75 49 6e 74 20 20 ry */. uInt
0450: 6e 29 29 3b 20 20 20 20 20 20 20 2f 2a 20 64 69 n)); /* di
0460: 63 74 69 6f 6e 61 72 79 20 6c 65 6e 67 74 68 20 ctionary length
0470: 2a 2f 0a 0a 65 78 74 65 72 6e 20 69 6e 74 20 69 */..extern int i
0480: 6e 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 5f 73 79 nflate_blocks_sy
0490: 6e 63 5f 70 6f 69 6e 74 20 4f 46 28 28 0a 20 20 nc_point OF((.
04a0: 20 20 69 6e 66 6c 61 74 65 5f 62 6c 6f 63 6b 73 inflate_blocks
04b0: 5f 73 74 61 74 65 66 20 2a 73 29 29 3b 0a _statef *s));.