aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm
diff options
context:
space:
mode:
authorWillem Jan Palenstijn2009-03-07 13:40:00 +0000
committerWillem Jan Palenstijn2009-03-07 13:40:00 +0000
commit7a88744b749e45efa8fb7339cf0989c5572f3863 (patch)
tree133d398f3952e2aa2069d49e783c5528fe0a8112 /engines/scumm
parent32e49fe2cf9c9fc1036b583dd39b8e2c351f81b4 (diff)
downloadscummvm-rg350-7a88744b749e45efa8fb7339cf0989c5572f3863.tar.gz
scummvm-rg350-7a88744b749e45efa8fb7339cf0989c5572f3863.tar.bz2
scummvm-rg350-7a88744b749e45efa8fb7339cf0989c5572f3863.zip
Patch #2671477: Fix wrong usage of strncat
svn-id: r39184
Diffstat (limited to 'engines/scumm')
-rw-r--r--engines/scumm/he/logic_he.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/scumm/he/logic_he.cpp b/engines/scumm/he/logic_he.cpp
index f7f4c1effc..9efb1c697c 100644
--- a/engines/scumm/he/logic_he.cpp
+++ b/engines/scumm/he/logic_he.cpp
@@ -86,9 +86,9 @@ int32 LogicHE::dispatch(int op, int numArgs, int32 *args) {
for (int i = 1; i < numArgs; i++) {
snprintf(tmp, 32, ", %d", args[i]);
- strncat(str, tmp, 256);
+ strncat(str, tmp, sizeof(str) - strlen(str) - 1);
}
- strncat(str, "])", 256);
+ strncat(str, "])", sizeof(str) - strlen(str) - 1);
debug(0, "%s", str);
#else