From c378aadc3f8b438fcb081945681dd2a370f617dc Mon Sep 17 00:00:00 2001 From: eriktorbjorn Date: Mon, 18 Jul 2011 10:31:13 +0200 Subject: DREAMWEB: Fix Valgrind warning --- engines/dreamweb/dreamweb.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'engines/dreamweb') diff --git a/engines/dreamweb/dreamweb.cpp b/engines/dreamweb/dreamweb.cpp index 85cb2c1983..719549cc7d 100644 --- a/engines/dreamweb/dreamweb.cpp +++ b/engines/dreamweb/dreamweb.cpp @@ -219,7 +219,13 @@ Common::Error DreamWebEngine::run() { syncSoundSettings(); _console = new DreamWebConsole(this); - _loadSavefile = Common::ConfigManager::instance().getInt("save_slot"); + if (ConfMan.hasKey("save_slot")) { + _enableSavingOrLoading = true; + _loadSavefile = ConfMan.getInt("save_slot"); + } else { + _enableSavingOrLoading = false; + _loadSavefile = -1; + } getTimerManager()->installTimerProc(vSyncInterrupt, 1000000 / 70, this); _context.__start(); -- cgit v1.2.3