[Scummvm-git-logs] scummvm master -> e85288e2b317c4e4a8b38dc6bd3dc067629243ad
sev-
sev at scummvm.org
Thu Jul 29 10:24:04 UTC 2021
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
e85288e2b3 DIRECTOR: Better handling of string resources.
Commit: e85288e2b317c4e4a8b38dc6bd3dc067629243ad
https://github.com/scummvm/scummvm/commit/e85288e2b317c4e4a8b38dc6bd3dc067629243ad
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2021-07-29T12:23:49+02:00
Commit Message:
DIRECTOR: Better handling of string resources.
In case there is garbage after \0 we will skip it all
Changed paths:
engines/director/archive.cpp
diff --git a/engines/director/archive.cpp b/engines/director/archive.cpp
index 64f58be255..882ece21cc 100644
--- a/engines/director/archive.cpp
+++ b/engines/director/archive.cpp
@@ -339,10 +339,14 @@ bool RIFFArchive::openStream(Common::SeekableReadStream *stream, uint32 startOff
byte nameSize = stream->readByte();
if (nameSize) {
+ bool skip = false;
for (uint8 i = 0; i < nameSize; i++) {
byte b = stream->readByte();
- if (b)
+ if (!b)
+ skip = true;
+
+ if (!skip)
name += b;
}
}
More information about the Scummvm-git-logs
mailing list