aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2013-04-27 08:43:06 +0300
committerEugene Sandulenko2013-04-27 08:43:06 +0300
commitb47c50a703aabace27eb47317c5f3424e3b4c22d (patch)
treef220ffdd7b2416ab1e14bcc335ec753854000f61
parentb77a5164142b6b54d461175f639218af4255a897 (diff)
downloadscummvm-rg350-b47c50a703aabace27eb47317c5f3424e3b4c22d.tar.gz
scummvm-rg350-b47c50a703aabace27eb47317c5f3424e3b4c22d.tar.bz2
scummvm-rg350-b47c50a703aabace27eb47317c5f3424e3b4c22d.zip
AGI: Null terminate string. CID 1003888
-rw-r--r--engines/agi/op_cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/agi/op_cmd.cpp b/engines/agi/op_cmd.cpp
index 0245f3936a..2366d97a82 100644
--- a/engines/agi/op_cmd.cpp
+++ b/engines/agi/op_cmd.cpp
@@ -1219,7 +1219,7 @@ void cmdWander(AgiGame *state, uint8 *p) {
void cmdSetGameID(AgiGame *state, uint8 *p) {
if (state->_curLogic->texts && (p0 - 1) <= state->_curLogic->numTexts)
- strncpy(state->id, state->_curLogic->texts[p0 - 1], 8);
+ Common::strlcpy(state->id, state->_curLogic->texts[p0 - 1], 8);
else
state->id[0] = 0;