aboutsummaryrefslogtreecommitdiff
path: root/gfx.cpp
diff options
context:
space:
mode:
authorJames Brown2002-03-24 16:35:17 +0000
committerJames Brown2002-03-24 16:35:17 +0000
commit7b93625b1759388807c7fc2eba3c16be19198b54 (patch)
tree53fa6db940c77ef9c41f2a515a83d6c6bedf4219 /gfx.cpp
parentad70aad4ca161d74fb5b115f4bf137aaed795b8b (diff)
downloadscummvm-rg350-7b93625b1759388807c7fc2eba3c16be19198b54.tar.gz
scummvm-rg350-7b93625b1759388807c7fc2eba3c16be19198b54.tar.bz2
scummvm-rg350-7b93625b1759388807c7fc2eba3c16be19198b54.zip
Add a few more uninited variables. Not done yet.
svn-id: r3812
Diffstat (limited to 'gfx.cpp')
-rw-r--r--gfx.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/gfx.cpp b/gfx.cpp
index 56785d286d..15d3c9a6fb 100644
--- a/gfx.cpp
+++ b/gfx.cpp
@@ -455,6 +455,9 @@ void Scumm::cyclePalette() {
if (valueToAdd < _vars[VAR_TIMER_NEXT])
valueToAdd = _vars[VAR_TIMER_NEXT];
+ if (!_colorCycle) // FIXME
+ return;
+
for (i=0,cycl=_colorCycle; i<16; i++,cycl++) {
if (cycl->delay &&
(cycl->counter+=valueToAdd) >= cycl->delay) {
@@ -499,7 +502,12 @@ void Scumm::moveMemInPalRes(int start, int end, byte direction) {
endptr2 = getResourceAddress(rtTemp, 5) + end * 6;
num = end - start;
-
+
+ if (!endptr) {
+ warning("moveMemInPalRes(%d,%d): Bad end pointer\n", start, end);
+ return;
+ }
+
if (!direction) {
memmove(tmp, endptr, 6);
memmove(startptr+6, startptr, num*6);