aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorSven Hesse2008-08-15 10:47:42 +0000
committerSven Hesse2008-08-15 10:47:42 +0000
commit4e0485197fcfb6e8807996e5bf179c0249a7369c (patch)
treeb3ea98cba49911c6bee51eee31380ea186b99008 /engines
parent22eaffcb343c688defbcd53445ad111390edb71d (diff)
downloadscummvm-rg350-4e0485197fcfb6e8807996e5bf179c0249a7369c.tar.gz
scummvm-rg350-4e0485197fcfb6e8807996e5bf179c0249a7369c.tar.bz2
scummvm-rg350-4e0485197fcfb6e8807996e5bf179c0249a7369c.zip
Fixing a segfault in the Bargon Attack menu
svn-id: r33896
Diffstat (limited to 'engines')
-rw-r--r--engines/gob/mult_v2.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/engines/gob/mult_v2.cpp b/engines/gob/mult_v2.cpp
index 20a81174e5..6bd4ddb625 100644
--- a/engines/gob/mult_v2.cpp
+++ b/engines/gob/mult_v2.cpp
@@ -510,10 +510,11 @@ void Mult_v2::playMultInit() {
if (!_animSurf) {
int16 width, height;
- for (int i = 0; i < _objCount; i++) {
- delete _objects[i].pPosX;
- delete _objects[i].pPosY;
- }
+ if (_objects)
+ for (int i = 0; i < _objCount; i++) {
+ delete _objects[i].pPosX;
+ delete _objects[i].pPosY;
+ }
delete[] _objects;