aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorStrangerke2014-05-25 17:38:28 +0200
committerStrangerke2014-05-25 17:38:28 +0200
commit58fcb43c192eb424897a89dd18ea4788e83deb3f (patch)
tree89ffbc3e7c7d91517a8eecc350f684324e2e9e5e /engines
parent26d5c3507a1c646965555e82364ab0618f5744da (diff)
downloadscummvm-rg350-58fcb43c192eb424897a89dd18ea4788e83deb3f.tar.gz
scummvm-rg350-58fcb43c192eb424897a89dd18ea4788e83deb3f.tar.bz2
scummvm-rg350-58fcb43c192eb424897a89dd18ea4788e83deb3f.zip
CINE: Add a safeguard to avoid incrementing a null pointer
Diffstat (limited to 'engines')
-rw-r--r--engines/cine/gfx.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/engines/cine/gfx.cpp b/engines/cine/gfx.cpp
index f6419ecafc..b9175cac72 100644
--- a/engines/cine/gfx.cpp
+++ b/engines/cine/gfx.cpp
@@ -1902,7 +1902,9 @@ void maskBgOverlay(const byte *bgPtr, const byte *maskPtr, int16 width, int16 he
destPtr++;
srcPtr++;
- maskPtr++;
+
+ if (maskPtr)
+ maskPtr++;
}
}