diff options
author | Sebastian Krzyszkowiak | 2019-06-17 19:08:43 +0200 |
---|---|---|
committer | Filippos Karapetis | 2019-06-17 23:08:00 +0300 |
commit | b428c23c75efae41fa7d907f5676faf05bc338e0 (patch) | |
tree | 4bc56f10973074ef259a6bf1badefac0f11ded68 /engines/sludge/fileset.cpp | |
parent | bdf85e33cbcf8ec6906e566dbcf6cd2a10f98901 (diff) | |
download | scummvm-rg350-b428c23c75efae41fa7d907f5676faf05bc338e0.tar.gz scummvm-rg350-b428c23c75efae41fa7d907f5676faf05bc338e0.tar.bz2 scummvm-rg350-b428c23c75efae41fa7d907f5676faf05bc338e0.zip |
SLUDGE: fix crash in ResourceManager::readResourceNames
Diffstat (limited to 'engines/sludge/fileset.cpp')
-rw-r--r-- | engines/sludge/fileset.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/engines/sludge/fileset.cpp b/engines/sludge/fileset.cpp index c9c3e7a43b..4f671ebbff 100644 --- a/engines/sludge/fileset.cpp +++ b/engines/sludge/fileset.cpp @@ -224,8 +224,7 @@ void ResourceManager::readResourceNames(Common::SeekableReadStream *readStream) _allResourceNames.reserve(numResourceNames); for (int fn = 0; fn < numResourceNames; fn++) { - _allResourceNames[fn].clear(); - _allResourceNames[fn] = readString(readStream); + _allResourceNames.push_back(readString(readStream)); debugC(2, kSludgeDebugDataLoad, "Resource %i: %s", fn, _allResourceNames[fn].c_str()); } } |