diff options
Diffstat (limited to 'deflate.c')
-rw-r--r-- | deflate.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -451,8 +451,10 @@ int ZEXPORT deflatePending (strm, pending, bits) | |||
451 | z_streamp strm; | 451 | z_streamp strm; |
452 | { | 452 | { |
453 | if (strm == Z_NULL || strm->state == Z_NULL) return Z_STREAM_ERROR; | 453 | if (strm == Z_NULL || strm->state == Z_NULL) return Z_STREAM_ERROR; |
454 | *pending = strm->state->pending; | 454 | if (pending != Z_NULL) |
455 | *bits = strm->state->bi_valid; | 455 | *pending = strm->state->pending; |
456 | if (bits != Z_NULL) | ||
457 | *bits = strm->state->bi_valid; | ||
456 | return Z_OK; | 458 | return Z_OK; |
457 | } | 459 | } |
458 | 460 | ||