diff options
author | Max Horn | 2008-08-09 22:42:03 +0000 |
---|---|---|
committer | Max Horn | 2008-08-09 22:42:03 +0000 |
commit | 39d2c3bdadfd2e27b109a82f63340d99a15cab44 (patch) | |
tree | 1014b70f6c96efeb2a27e3c652b7137765d9b436 | |
parent | ef3b72d5e4a7b1772799224fe94ade279ea2fb5a (diff) | |
download | scummvm-rg350-39d2c3bdadfd2e27b109a82f63340d99a15cab44.tar.gz scummvm-rg350-39d2c3bdadfd2e27b109a82f63340d99a15cab44.tar.bz2 scummvm-rg350-39d2c3bdadfd2e27b109a82f63340d99a15cab44.zip |
If no default config file is present, just don't load it, instead of crashing
svn-id: r33729
-rw-r--r-- | common/config-manager.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/common/config-manager.cpp b/common/config-manager.cpp index a424c4f6c7..138fcc201f 100644 --- a/common/config-manager.cpp +++ b/common/config-manager.cpp @@ -64,9 +64,9 @@ void ConfigManager::loadDefaultConfigFile() { SeekableReadStream *stream = g_system->openConfigFileForReading(); _filename.clear(); // clear the filename to indicate that we are using the default config file - // ... load it ... - assert(stream); - loadFromStream(*stream); + // ... load it, if available ... + if (stream) + loadFromStream(*stream); // ... and close it again. delete stream; |