diff options
author | whiterandrek | 2018-05-22 22:20:32 +0300 |
---|---|---|
committer | Eugene Sandulenko | 2018-06-28 23:51:32 +0200 |
commit | 65e899e723b6f8258d1aa63f7cd50805293862a3 (patch) | |
tree | b5325fc1f7e506faff51f22a7e321e450e4d07ed /engines | |
parent | 174b317facdf127967841b5de5b2226734d184bf (diff) | |
download | scummvm-rg350-65e899e723b6f8258d1aa63f7cd50805293862a3.tar.gz scummvm-rg350-65e899e723b6f8258d1aa63f7cd50805293862a3.tar.bz2 scummvm-rg350-65e899e723b6f8258d1aa63f7cd50805293862a3.zip |
PINK: fix finding of resource description
Diffstat (limited to 'engines')
-rw-r--r-- | engines/pink/resource_mgr.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/engines/pink/resource_mgr.cpp b/engines/pink/resource_mgr.cpp index 810f412553..0981d8e167 100644 --- a/engines/pink/resource_mgr.cpp +++ b/engines/pink/resource_mgr.cpp @@ -55,21 +55,21 @@ Sound *ResourceMgr::loadSound(Common::String &name) { Common::SafeSeekableSubReadStream *ResourceMgr::getResourceStream(Common::String &name) { Common::SeekableReadStream *stream; - ResourceDescription &desc = _resDescTable[0]; + ResourceDescription *desc; for (uint i = 0; i < _resCount; ++i) { if (name.compareToIgnoreCase(_resDescTable[i].name) == 0) - desc = _resDescTable[i]; + desc = &_resDescTable[i]; } - if (desc.inBro) + if (desc->inBro) stream = _game->getBro(); else stream = _game->getOrb(); - stream->seek(desc.offset); + stream->seek(desc->offset); - return new Common::SafeSeekableSubReadStream(stream, desc.offset, - desc.offset + desc.size); + return new Common::SafeSeekableSubReadStream(stream, desc->offset, + desc->offset + desc->size); } PinkEngine *ResourceMgr::getGame() const { |