summaryrefslogtreecommitdiff
path: root/src/game
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2014-04-23 21:12:09 +0000
committerrubidium <rubidium@openttd.org>2014-04-23 21:12:09 +0000
commit5b82822c12e014771dceaf9d909e1c0f3653c5a9 (patch)
tree1cf02e076eb61eb94d9064c7cb02bbe85ecb9a6c /src/game
parentef4c2ce0317ae583e837722b6a41ea44cd83da71 (diff)
downloadopenttd-5b82822c12e014771dceaf9d909e1c0f3653c5a9.tar.xz
(svn r26486) -Codechange: replace a number of snprintfs with seprintf
Diffstat (limited to 'src/game')
-rw-r--r--src/game/game_scanner.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/game/game_scanner.cpp b/src/game/game_scanner.cpp
index 5cdb30845..a251f3386 100644
--- a/src/game/game_scanner.cpp
+++ b/src/game/game_scanner.cpp
@@ -61,7 +61,7 @@ GameInfo *GameScannerInfo::FindInfo(const char *nameParam, int versionParam, boo
if (force_exact_match) {
/* Try to find a direct 'name.version' match */
char game_name_tmp[1024];
- snprintf(game_name_tmp, sizeof(game_name_tmp), "%s.%d", game_name, versionParam);
+ seprintf(game_name_tmp, lastof(game_name_tmp), "%s.%d", game_name, versionParam);
strtolower(game_name_tmp);
if (this->info_list.find(game_name_tmp) != this->info_list.end()) return static_cast<GameInfo *>(this->info_list[game_name_tmp]);
}
@@ -101,7 +101,7 @@ GameLibrary *GameScannerLibrary::FindLibrary(const char *library, int version)
{
/* Internally we store libraries as 'library.version' */
char library_name[1024];
- snprintf(library_name, sizeof(library_name), "%s.%d", library, version);
+ seprintf(library_name, lastof(library_name), "%s.%d", library, version);
strtolower(library_name);
/* Check if the library + version exists */