diff options
| author | Paul Gilbert | 2007-11-30 23:58:29 +0000 |
|---|---|---|
| committer | Paul Gilbert | 2007-11-30 23:58:29 +0000 |
| commit | 5cf2a45b77887ddb0fed7d1ad7d75474bcf2c7de (patch) | |
| tree | e1ca12ee04df4e22e88d5ade8437581932d879f0 | |
| parent | 98545ad4e539ee42f87f3ad2399e55d0bafcf8b7 (diff) | |
| download | scummvm-rg350-5cf2a45b77887ddb0fed7d1ad7d75474bcf2c7de.tar.gz scummvm-rg350-5cf2a45b77887ddb0fed7d1ad7d75474bcf2c7de.tar.bz2 scummvm-rg350-5cf2a45b77887ddb0fed7d1ad7d75474bcf2c7de.zip | |
Fixed endian bug in the decoding of strings
svn-id: r29674
| -rw-r--r-- | engines/lure/strings.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/lure/strings.cpp b/engines/lure/strings.cpp index c05f01a511..1436b92fb8 100644 --- a/engines/lure/strings.cpp +++ b/engines/lure/strings.cpp @@ -228,11 +228,11 @@ void StringData::getString(uint16 stringId, char *dest, const char *hotspotName, // Returns the name or fragment of word at the specified index in the names resource char *StringData::getName(uint8 nameIndex) { - uint16 numNames = *((uint16 *) _names->data()) / 2; + uint16 numNames = READ_LE_UINT16(_names->data()) / 2; if (nameIndex >= numNames) error("Invalid name index was passed to getCharacterName"); - uint16 nameStart = *((uint16 *) (_names->data() + (nameIndex * 2))); + uint16 nameStart = READ_LE_UINT16(_names->data() + (nameIndex * 2)); return (char *) (_names->data() + nameStart); } |
