1.1 --- a/extensions/tf2/extension.cpp Thu Jun 26 08:07:47 2008 +0000
1.2 +++ b/extensions/tf2/extension.cpp Sun Jun 29 03:27:15 2008 +0000
1.3 @@ -65,14 +65,14 @@
1.4 {
1.5 if (strcmp(g_pSM->GetGameFolderName(), "tf") != 0)
1.6 {
1.7 - snprintf(error, maxlength, "Cannot Load TF2 Extension on mods other than TF2");
1.8 + UTIL_Format(error, maxlength, "Cannot Load TF2 Extension on mods other than TF2");
1.9 return false;
1.10 }
1.11
1.12 ServerClass *sc = UTIL_FindServerClass("CTFPlayer");
1.13 if (sc == NULL)
1.14 {
1.15 - snprintf(error, maxlength, "Could not find CTFPlayer server class");
1.16 + UTIL_Format(error, maxlength, "Could not find CTFPlayer server class");
1.17 return false;
1.18 }
1.19
1.20 @@ -80,18 +80,18 @@
1.21
1.22 if (!UTIL_FindDataTable(sc->m_pTable, "DT_TFPlayerShared", playerSharedOffset, 0))
1.23 {
1.24 - snprintf(error, maxlength, "Could not find DT_TFPlayerShared data table");
1.25 + UTIL_Format(error, maxlength, "Could not find DT_TFPlayerShared data table");
1.26 return false;
1.27 }
1.28
1.29 sharesys->AddDependency(myself, "bintools.ext", true, true);
1.30
1.31 - char conf_error[255];
1.32 + char conf_error[255] = "";
1.33 if (!gameconfs->LoadGameConfigFile("sm-tf2.games", &g_pGameConf, conf_error, sizeof(conf_error)))
1.34 {
1.35 if (conf_error)
1.36 {
1.37 - snprintf(error, maxlength, "Could not read sm-tf2.games.txt: %s", conf_error);
1.38 + UTIL_Format(error, maxlength, "Could not read sm-tf2.games.txt: %s", conf_error);
1.39 }
1.40 return false;
1.41 }