COMMON: Initialize more z_stream fields before calling inflateInit2.
The zlib documentation and examples claim this is needed, as spotted by LordHoto.
This commit is contained in:
parent
62a22b6293
commit
a8896be85e
1 changed files with 2 additions and 0 deletions
|
@ -76,6 +76,8 @@ public:
|
|||
_stream.zalloc = Z_NULL;
|
||||
_stream.zfree = Z_NULL;
|
||||
_stream.opaque = Z_NULL;
|
||||
_stream.avail_in = 0;
|
||||
_stream.next_in = Z_NULL;
|
||||
|
||||
// Verify file header is correct
|
||||
w->seek(0, SEEK_SET);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue