[Scummvm-cvs-logs] scummvm master -> c5363006edf0744adfd0b48a67389213b8bea9ba

clone2727 clone2727 at gmail.com
Thu Apr 19 17:55:02 CEST 2012


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:
c5363006ed GRAPHICS: Only accept JPEG CompressedQuickTime PICT opcodes


Commit: c5363006edf0744adfd0b48a67389213b8bea9ba
    https://github.com/scummvm/scummvm/commit/c5363006edf0744adfd0b48a67389213b8bea9ba
Author: Matthew Hoops (clone2727 at gmail.com)
Date: 2012-04-19T08:49:06-07:00

Commit Message:
GRAPHICS: Only accept JPEG CompressedQuickTime PICT opcodes

Changed paths:
    graphics/decoders/pict.cpp



diff --git a/graphics/decoders/pict.cpp b/graphics/decoders/pict.cpp
index 9573420..9963873 100644
--- a/graphics/decoders/pict.cpp
+++ b/graphics/decoders/pict.cpp
@@ -541,10 +541,14 @@ void PICTDecoder::decodeCompressedQuickTime(Common::SeekableReadStream &stream)
 	// Now we've reached the image descriptor, so read the relevant data from that
 	uint32 idStart = stream.pos();
 	uint32 idSize = stream.readUint32BE();
-	stream.skip(40); // miscellaneous stuff
+	uint32 codec = stream.readUint32BE();
+	stream.skip(36); // miscellaneous stuff
 	uint32 jpegSize = stream.readUint32BE();
 	stream.skip(idSize - (stream.pos() - idStart)); // more useless stuff
 
+	if (codec != MKTAG('j', 'p', 'e', 'g'))
+		error("Unhandled CompressedQuickTime format '%s'", tag2str(codec));
+
 	Common::SeekableSubReadStream jpegStream(&stream, stream.pos(), stream.pos() + jpegSize);
 
 	JPEGDecoder jpeg;






More information about the Scummvm-git-logs mailing list