aboutsummaryrefslogtreecommitdiff
path: root/engines/tinsel/handle.cpp
diff options
context:
space:
mode:
authorDavid Turner2010-05-31 15:16:46 +0000
committerDavid Turner2010-05-31 15:16:46 +0000
commitd1da820a75a3a8f921c0b7cd1ae26bf6f7cb6729 (patch)
treed126ef7df3ced44227a5e7fcbba87d1b00493a21 /engines/tinsel/handle.cpp
parent753fdd6c123e3be04057ad4e4e35a95a3c39a2b7 (diff)
downloadscummvm-rg350-d1da820a75a3a8f921c0b7cd1ae26bf6f7cb6729.tar.gz
scummvm-rg350-d1da820a75a3a8f921c0b7cd1ae26bf6f7cb6729.tar.bz2
scummvm-rg350-d1da820a75a3a8f921c0b7cd1ae26bf6f7cb6729.zip
Fix for DW2 engine abort with message "Cannot find file hienergy.sc!".
Bug introduced by r49086 change which could trim the last character of filenames. svn-id: r49356
Diffstat (limited to 'engines/tinsel/handle.cpp')
-rw-r--r--engines/tinsel/handle.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/tinsel/handle.cpp b/engines/tinsel/handle.cpp
index de573feee2..b006f718b7 100644
--- a/engines/tinsel/handle.cpp
+++ b/engines/tinsel/handle.cpp
@@ -288,7 +288,7 @@ void LoadFile(MEMHANDLE *pH) {
}
// extract and zero terminate the filename
- Common::strlcpy(szFilename, pH->szName, sizeof(pH->szName));
+ Common::strlcpy(szFilename, pH->szName, sizeof(pH->szName)+1);
if (f.open(szFilename)) {
// read the data