[Scummvm-cvs-logs] scummvm master -> 8e2e3172941ae2f79f2ccdb321b7ff539bcca41e
clone2727
clone2727 at gmail.com
Thu Dec 13 06:41:19 CET 2012
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
6b6e6c92c7 COMMON: Fix potential uninitialized memory usage
8e2e317294 PEGASUS: Fix invalid use of RipTimer
Commit: 6b6e6c92c7c797560745651c1b16f1b5764bf297
https://github.com/scummvm/scummvm/commit/6b6e6c92c7c797560745651c1b16f1b5764bf297
Author: Matthew Hoops (clone2727 at gmail.com)
Date: 2012-12-12T21:39:48-08:00
Commit Message:
COMMON: Fix potential uninitialized memory usage
Changed paths:
common/macresman.cpp
diff --git a/common/macresman.cpp b/common/macresman.cpp
index f2f020c..00562f7 100644
--- a/common/macresman.cpp
+++ b/common/macresman.cpp
@@ -360,8 +360,8 @@ bool MacResManager::load(SeekableReadStream &stream) {
_mapLength = stream.readUint32BE();
// do sanity check
- if (_dataOffset >= (uint32)stream.size() || _mapOffset >= (uint32)stream.size() ||
- _dataLength + _mapLength > (uint32)stream.size()) {
+ if (stream.eos() || _dataOffset >= (uint32)stream.size() || _mapOffset >= (uint32)stream.size() ||
+ _dataLength + _mapLength > (uint32)stream.size()) {
_resForkOffset = -1;
_mode = kResForkNone;
return false;
Commit: 8e2e3172941ae2f79f2ccdb321b7ff539bcca41e
https://github.com/scummvm/scummvm/commit/8e2e3172941ae2f79f2ccdb321b7ff539bcca41e
Author: Matthew Hoops (clone2727 at gmail.com)
Date: 2012-12-12T21:39:49-08:00
Commit Message:
PEGASUS: Fix invalid use of RipTimer
Changed paths:
engines/pegasus/neighborhood/tsa/fulltsa.cpp
diff --git a/engines/pegasus/neighborhood/tsa/fulltsa.cpp b/engines/pegasus/neighborhood/tsa/fulltsa.cpp
index b598841..9b843da 100644
--- a/engines/pegasus/neighborhood/tsa/fulltsa.cpp
+++ b/engines/pegasus/neighborhood/tsa/fulltsa.cpp
@@ -622,6 +622,13 @@ void RipTimer::draw(const Common::Rect &updateRect) {
}
void RipTimer::timeChanged(const TimeValue newTime) {
+ // WORKAROUND: If the timer isn't running, don't run the following code.
+ // Fixes use of the code when it shouldn't be running (since this is an
+ // IdlerAnimation, this is called on useIdleTime() but this specific
+ // timer only makes sense when used as an actual timer).
+ if (!isRunning())
+ return;
+
Common::Rect bounds;
getBounds(bounds);
More information about the Scummvm-git-logs
mailing list