[Scummvm-cvs-logs] scummvm master -> 0572fa5d351c0cd1a34a69df76c81c48382be81b

clone2727 clone2727 at gmail.com
Sat Mar 1 18:06:49 CET 2014


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
0572fa5d35 IMAGE: Handle bitmaps with an image size field of 0


Commit: 0572fa5d351c0cd1a34a69df76c81c48382be81b
    https://github.com/scummvm/scummvm/commit/0572fa5d351c0cd1a34a69df76c81c48382be81b
Author: Matthew Hoops (clone2727 at gmail.com)
Date: 2014-03-01T09:05:47-08:00

Commit Message:
IMAGE: Handle bitmaps with an image size field of 0

Changed paths:
    image/bmp.cpp



diff --git a/image/bmp.cpp b/image/bmp.cpp
index cdf6e40..28eb049 100644
--- a/image/bmp.cpp
+++ b/image/bmp.cpp
@@ -119,6 +119,10 @@ bool BitmapDecoder::loadStream(Common::SeekableReadStream &stream) {
 	if (!_codec)
 		return false;
 
+	// If the image size is zero, set it to the rest of the stream.
+	if (imageSize == 0)
+		imageSize = stream.size() - imageOffset;
+
 	// Grab the frame data
 	Common::SeekableSubReadStream subStream(&stream, imageOffset, imageOffset + imageSize);
 






More information about the Scummvm-git-logs mailing list