diff options
| author | Mark Adler <madler@alumni.caltech.edu> | 2014-12-29 00:18:42 -0800 |
|---|---|---|
| committer | Mark Adler <madler@alumni.caltech.edu> | 2014-12-29 00:18:42 -0800 |
| commit | 5370d99a2affe0b040550cffbc0ba8fa790594b3 (patch) | |
| tree | 44f7fc802d1936a5612e4e6a6472f5cae40bba87 | |
| parent | 283520baf786b81cfd97fe56909b7e8f2529eb22 (diff) | |
| download | zlib-5370d99a2affe0b040550cffbc0ba8fa790594b3.tar.gz zlib-5370d99a2affe0b040550cffbc0ba8fa790594b3.tar.bz2 zlib-5370d99a2affe0b040550cffbc0ba8fa790594b3.zip | |
Add inflateCodesUsed() function for internal use.
| -rw-r--r-- | inflate.c | 9 |
1 files changed, 9 insertions, 0 deletions
| @@ -1510,3 +1510,12 @@ z_streamp strm; | |||
| 1510 | (state->mode == COPY ? state->length : | 1510 | (state->mode == COPY ? state->length : |
| 1511 | (state->mode == MATCH ? state->was - state->length : 0)); | 1511 | (state->mode == MATCH ? state->was - state->length : 0)); |
| 1512 | } | 1512 | } |
| 1513 | |||
| 1514 | unsigned long ZEXPORT inflateCodesUsed(strm) | ||
| 1515 | z_streamp strm; | ||
| 1516 | { | ||
| 1517 | struct inflate_state FAR *state; | ||
| 1518 | if (strm == Z_NULL || strm->state == Z_NULL) return -1L; | ||
| 1519 | state = (struct inflate_state FAR *)strm->state; | ||
| 1520 | return state->next - state->codes; | ||
| 1521 | } | ||
