mirror of
https://github.com/libretro/scummvm.git
synced 2024-11-27 11:20:40 +00:00
IMAGE: Init memory before usage
This commit is contained in:
parent
1a084f1541
commit
3b5236c9de
@ -340,6 +340,8 @@ void PICTDecoder::unpackBitsRect(Common::SeekableReadStream &stream, bool withPa
|
||||
uint32 lineSize = MAX<int>(width * bytesPerPixel + (8 * 2 / packBitsData.pixMap.pixelSize), packBitsData.pixMap.rowBytes);
|
||||
byte *buffer = new byte[lineSize * height];
|
||||
|
||||
memset(buffer, 0, lineSize * height);
|
||||
|
||||
// Read in amount of data per row
|
||||
for (uint16 i = 0; i < packBitsData.pixMap.bounds.height(); i++) {
|
||||
// NOTE: Compression 0 is "default". The format in SCI games is packed when 0.
|
||||
|
Loading…
Reference in New Issue
Block a user