aboutsummaryrefslogtreecommitdiff
path: root/engines/macventure
diff options
context:
space:
mode:
authorBorja Lorente2016-08-21 13:19:08 +0200
committerBorja Lorente2016-08-21 13:19:08 +0200
commit1210f05842b927ef07b4817552002b97cdd6906e (patch)
treeced47aaeaa7d293351b0345ab6a5d06f61a135a3 /engines/macventure
parent059c9a64d9505901a0c150e55af3c2ded372a214 (diff)
downloadscummvm-rg350-1210f05842b927ef07b4817552002b97cdd6906e.tar.gz
scummvm-rg350-1210f05842b927ef07b4817552002b97cdd6906e.tar.bz2
scummvm-rg350-1210f05842b927ef07b4817552002b97cdd6906e.zip
MACVENTURE: Fix upper limit in savefile names
Diffstat (limited to 'engines/macventure')
-rw-r--r--engines/macventure/saveload.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/engines/macventure/saveload.cpp b/engines/macventure/saveload.cpp
index e5cc9b6fa5..1b56980ecd 100644
--- a/engines/macventure/saveload.cpp
+++ b/engines/macventure/saveload.cpp
@@ -63,8 +63,8 @@ SaveStateDescriptor loadMetaData(Common::SeekableReadStream *s, int slot) {
}
void writeMetaData(Common::OutSaveFile *file, Common::String desc) {
- if (desc.size() >= (1 << (MACVENTURE_DESC_LENGTH * 4))) {
- desc.erase((1 << (MACVENTURE_DESC_LENGTH * 4)) - 1);
+ if (desc.size() >= (1 << (MACVENTURE_DESC_LENGTH * 8))) {
+ desc.erase((1 << (MACVENTURE_DESC_LENGTH * 8)) - 1);
}
file->writeString(desc);
file->writeUint32BE(MACVENTURE_SAVE_HEADER);
@@ -121,8 +121,8 @@ bool MacVentureEngine::scummVMSaveLoadDialog(bool isSave) {
desc = dialog.createDefaultSaveDescription(slot);
}
- if (desc.size() > (1 << MACVENTURE_DESC_LENGTH * 4) - 1)
- desc = Common::String(desc.c_str(), (1 << MACVENTURE_DESC_LENGTH * 4) - 1);
+ if (desc.size() > (1 << MACVENTURE_DESC_LENGTH * 8) - 1)
+ desc = Common::String(desc.c_str(), (1 << MACVENTURE_DESC_LENGTH * 8) - 1);
if (slot < 0)
return true;