mirror of
https://github.com/love2d/love.git
synced 2026-08-12 00:20:52 +02:00
Merge pull request #2320 from Syyrion/zlib-decompress-fix
Fix zlib decompression incomplete data check
This commit is contained in:
@@ -246,7 +246,7 @@ private:
|
||||
if (err != Z_STREAM_END)
|
||||
{
|
||||
inflateEnd(&stream);
|
||||
if (err == Z_NEED_DICT || (err == Z_BUF_ERROR && stream.avail_in == 0))
|
||||
if (err == Z_NEED_DICT || (err == Z_BUF_ERROR && stream.avail_out > 0 && stream.avail_in == 0))
|
||||
return Z_DATA_ERROR;
|
||||
return err;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user