diff options
| -rw-r--r-- | gzwrite.c | 2 |
1 files changed, 1 insertions, 1 deletions
| @@ -609,7 +609,7 @@ int ZEXPORT gzsetparams(file, level, strategy) | |||
| 609 | strm = &(state->strm); | 609 | strm = &(state->strm); |
| 610 | 610 | ||
| 611 | /* check that we're writing and that there's no error */ | 611 | /* check that we're writing and that there's no error */ |
| 612 | if (state->mode != GZ_WRITE || state->err != Z_OK) | 612 | if (state->mode != GZ_WRITE || state->err != Z_OK || state->direct) |
| 613 | return Z_STREAM_ERROR; | 613 | return Z_STREAM_ERROR; |
| 614 | 614 | ||
| 615 | /* if no change is requested, then do nothing */ | 615 | /* if no change is requested, then do nothing */ |
