summaryrefslogtreecommitdiff
path: root/src/saveload
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2014-04-23 20:44:42 +0000
committerfrosch <frosch@openttd.org>2014-04-23 20:44:42 +0000
commitef4c2ce0317ae583e837722b6a41ea44cd83da71 (patch)
treec0c3d77ac495a6b9257cd7de4dadc6712db1acc8 /src/saveload
parent56e8ea6ddef08eb6ad1a28d06dddecb902e1bc04 (diff)
downloadopenttd-ef4c2ce0317ae583e837722b6a41ea44cd83da71.tar.xz
(svn r26485) -Codechange: Replace ttd_strlcpy and ttd_strlcat with strecpy and strecat.
Diffstat (limited to 'src/saveload')
-rw-r--r--src/saveload/ai_sl.cpp2
-rw-r--r--src/saveload/game_sl.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/saveload/ai_sl.cpp b/src/saveload/ai_sl.cpp
index b86c5541e..2a927504b 100644
--- a/src/saveload/ai_sl.cpp
+++ b/src/saveload/ai_sl.cpp
@@ -41,7 +41,7 @@ static void SaveReal_AIPL(int *index_ptr)
AIConfig *config = AIConfig::GetConfig(index);
if (config->HasScript()) {
- ttd_strlcpy(_ai_saveload_name, config->GetName(), lengthof(_ai_saveload_name));
+ strecpy(_ai_saveload_name, config->GetName(), lastof(_ai_saveload_name));
_ai_saveload_version = config->GetVersion();
} else {
/* No AI is configured for this so store an empty string as name. */
diff --git a/src/saveload/game_sl.cpp b/src/saveload/game_sl.cpp
index 629bc271a..d9fc4ce2f 100644
--- a/src/saveload/game_sl.cpp
+++ b/src/saveload/game_sl.cpp
@@ -40,7 +40,7 @@ static void SaveReal_GSDT(int *index_ptr)
GameConfig *config = GameConfig::GetConfig();
if (config->HasScript()) {
- ttd_strlcpy(_game_saveload_name, config->GetName(), lengthof(_game_saveload_name));
+ strecpy(_game_saveload_name, config->GetName(), lastof(_game_saveload_name));
_game_saveload_version = config->GetVersion();
} else {
/* No GameScript is configured for this so store an empty string as name. */