From db369838e20dc29a6bb1ebc2455ca17f0add069b Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Fri, 15 Oct 2010 15:23:53 +0000 Subject: [PATCH] AGOS: Fixed code analysis warnings - bug #3087828 svn-id: r53503 --- engines/agos/script_pn.cpp | 2 +- engines/agos/verb_pn.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/engines/agos/script_pn.cpp b/engines/agos/script_pn.cpp index 0391d67b31a..909c051362f 100644 --- a/engines/agos/script_pn.cpp +++ b/engines/agos/script_pn.cpp @@ -890,7 +890,7 @@ int AGOSEngine_PN::doline(int needsave) { int myTag = ++_tagOfActiveDoline; // Obtain a unique tag for this doline invocation _dolineReturnVal = 0; - if (needsave) + if (_stackbase && needsave) _stackbase->tagOfParentDoline = myTag; do { diff --git a/engines/agos/verb_pn.cpp b/engines/agos/verb_pn.cpp index 129e1dec0e0..b36f634ec02 100644 --- a/engines/agos/verb_pn.cpp +++ b/engines/agos/verb_pn.cpp @@ -185,7 +185,7 @@ void AGOSEngine_PN::hitBox5(HitArea *ha) { _mousePrintFG++; _mouseString = (const char *)"take \0"; - _mouseString1 = getMessage(_objectName1, _dragStore->msg1); + _mouseString1 = _dragStore ? getMessage(_objectName1, _dragStore->msg1) : ""; if (_dragStore->flags & kOBFRoomBox) _mouseString1 = (const char *)"all\r";