From da2ddbb8f482003a471b4f27eb222d4f9a23ea7b Mon Sep 17 00:00:00 2001 From: Strangerke Date: Fri, 25 Oct 2013 22:40:09 +0200 Subject: AVALANCHE: Fix 3 issues reported by Coverity. --- engines/avalanche/background.cpp | 1 + engines/avalanche/graphics.cpp | 1 + engines/avalanche/parser.cpp | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) (limited to 'engines/avalanche') diff --git a/engines/avalanche/background.cpp b/engines/avalanche/background.cpp index c84c049c8f..4d71550213 100644 --- a/engines/avalanche/background.cpp +++ b/engines/avalanche/background.cpp @@ -37,6 +37,7 @@ const int16 Background::kOnDisk = -1; Background::Background(AvalancheEngine *vm) { _vm = vm; _spriteNum = 0; + _nextBell = 0; } Background::~Background() { diff --git a/engines/avalanche/graphics.cpp b/engines/avalanche/graphics.cpp index 25b01d65f3..d7c32cb1fc 100644 --- a/engines/avalanche/graphics.cpp +++ b/engines/avalanche/graphics.cpp @@ -49,6 +49,7 @@ const MouseHotspotType GraphicManager::kMouseHotSpots[9] = { GraphicManager::GraphicManager(AvalancheEngine *vm) { _vm = vm; + setDialogColor(kColorBlack, kColorWhite); } GraphicManager::~GraphicManager() { diff --git a/engines/avalanche/parser.cpp b/engines/avalanche/parser.cpp index 297f27ffb8..b4cb64f70f 100644 --- a/engines/avalanche/parser.cpp +++ b/engines/avalanche/parser.cpp @@ -1013,7 +1013,7 @@ bool Parser::isHolding() { bool holdingResult = false; - if (_thing > 100) + if (_thing >= 100) _vm->_dialogs->displayText("Be reasonable!"); else if (_thing <= kObjectNum) { if (!_vm->_objects[_thing - 1]) -- cgit v1.2.3