zlib: protect CLEAR_HASH macro
Fix compilation warning (and probably bug): deflate.c l608 some parts of macro expansion are not guarded by this ‘else’ clause
This commit is contained in:
@@ -195,9 +195,10 @@ local const config configuration_table[10] = {
|
|||||||
* Initialize the hash table (avoiding 64K overflow for 16 bit systems).
|
* Initialize the hash table (avoiding 64K overflow for 16 bit systems).
|
||||||
* prev[] will be initialized on the fly.
|
* prev[] will be initialized on the fly.
|
||||||
*/
|
*/
|
||||||
#define CLEAR_HASH(s) \
|
#define CLEAR_HASH(s) {\
|
||||||
s->head[s->hash_size-1] = NIL; \
|
s->head[s->hash_size-1] = NIL; \
|
||||||
zmemzero((Bytef *)s->head, (unsigned)(s->hash_size-1)*sizeof(*s->head));
|
zmemzero((Bytef *)s->head, (unsigned)(s->hash_size-1)*sizeof(*s->head)); \
|
||||||
|
}
|
||||||
|
|
||||||
/* ===========================================================================
|
/* ===========================================================================
|
||||||
* Slide the hash table when sliding the window down (could be avoided with 32
|
* Slide the hash table when sliding the window down (could be avoided with 32
|
||||||
|
|||||||
Reference in New Issue
Block a user