* deflate switches away from Z_RLE.)
*/
static block_state deflate_rle(deflate_state *s, int flush) {
- int bflush; /* set if current block must be flushed */
+ int bflush = 0; /* set if current block must be flushed */
unsigned int prev; /* byte at distance one to match */
unsigned char *scan, *strend; /* scan goes up to strend for length of run */
* (It will be regenerated if this run of deflate switches away from Huffman.)
*/
static block_state deflate_huff(deflate_state *s, int flush) {
- int bflush; /* set if current block must be flushed */
+ int bflush = 0; /* set if current block must be flushed */
for (;;) {
/* Make sure that we have a literal to write. */
*/
ZLIB_INTERNAL block_state deflate_fast(deflate_state *s, int flush) {
IPos hash_head; /* head of the hash chain */
- int bflush; /* set if current block must be flushed */
+ int bflush = 0; /* set if current block must be flushed */
for (;;) {
/* Make sure that we always have enough lookahead, except
};
static int emit_match(deflate_state *s, struct match match) {
- int flush = 0;
+ int bflush = 0;
/* matches that are not long enough we need to emit as literals */
if (match.match_length < MIN_MATCH) {
while (match.match_length) {
- flush += zng_tr_tally_lit(s, s->window[match.strstart]);
+ bflush += zng_tr_tally_lit(s, s->window[match.strstart]);
s->lookahead--;
match.strstart++;
match.match_length--;
}
- return flush;
+ return bflush;
}
check_match(s, match.strstart, match.match_start, match.match_length);
- flush += zng_tr_tally_dist(s, match.strstart - match.match_start, match.match_length - MIN_MATCH);
+ bflush += zng_tr_tally_dist(s, match.strstart - match.match_start, match.match_length - MIN_MATCH);
s->lookahead -= match.match_length;
- return flush;
+ return bflush;
}
static void insert_match(deflate_state *s, struct match match) {
for (;;) {
IPos hash_head = 0; /* head of the hash chain */
- int bflush; /* set if current block must be flushed */
+ int bflush = 0; /* set if current block must be flushed */
/* Make sure that we always have enough lookahead, except
* at the end of the input file. We need MAX_MATCH bytes
*/
ZLIB_INTERNAL block_state deflate_slow(deflate_state *s, int flush) {
IPos hash_head; /* head of hash chain */
- int bflush; /* set if current block must be flushed */
+ int bflush = 0; /* set if current block must be flushed */
/* Process the input block. */
for (;;) {
}
#endif /*NOT_TWEAK_COMPILER*/
- if (bflush) FLUSH_BLOCK(s, 0);
+ if (bflush)
+ FLUSH_BLOCK(s, 0);
} else if (s->match_available) {
/* If there was no match at the previous position, output a
*/
Tracevv((stderr, "%c", s->window[s->strstart-1]));
bflush = zng_tr_tally_lit(s, s->window[s->strstart-1]);
- if (bflush) {
+ if (bflush)
FLUSH_BLOCK_ONLY(s, 0);
- }
s->strstart++;
s->lookahead--;
if (s->strm->avail_out == 0)