Allow deflatePrime() to insert bits in the middle of a stream.

This allows the insertion of multiple empty static blocks for the
purpose of efficiently bringing a stream to a byte boundary.
This commit is contained in:
Mark Adler
2012-01-07 09:54:40 -08:00
parent 19761b8506
commit 263b1a05b0
4 changed files with 26 additions and 13 deletions

View File

@@ -1,5 +1,5 @@
/* deflate.h -- internal compression state
* Copyright (C) 1995-2010 Jean-loup Gailly
* Copyright (C) 1995-2012 Jean-loup Gailly
* For conditions of distribution and use, see copyright notice in zlib.h
*/
@@ -48,6 +48,9 @@
#define MAX_BITS 15
/* All codes must not exceed MAX_BITS bits */
#define Buf_size 16
/* size of bit buffer in bi_buf */
#define INIT_STATE 42
#define EXTRA_STATE 69
#define NAME_STATE 73