22 changes: 12 additions & 10 deletions src/game/server/score/sql_score.cpp
Expand Up @@ -262,7 +262,8 @@ void CSqlScore::MapVote(int ClientID, const char* MapName)
Tmp->m_ClientID = ClientID;
Tmp->m_RequestedMap = MapName;
str_copy(Tmp->m_aFuzzyMap, MapName, sizeof(Tmp->m_aFuzzyMap));
sqlstr::FuzzyString(Tmp->m_aFuzzyMap);
sqlstr::ClearString(Tmp->m_aFuzzyMap, sizeof(Tmp->m_aFuzzyMap));
sqlstr::FuzzyString(Tmp->m_aFuzzyMap, sizeof(Tmp->m_aFuzzyMap));

void *VoteThread = thread_init(ExecSqlFunc, new CSqlExecData(MapVoteThread, Tmp));
thread_detach(VoteThread);
Expand Down Expand Up @@ -357,7 +358,8 @@ void CSqlScore::MapInfo(int ClientID, const char* MapName)
Tmp->m_ClientID = ClientID;
Tmp->m_RequestedMap = MapName;
str_copy(Tmp->m_aFuzzyMap, MapName, sizeof(Tmp->m_aFuzzyMap));
sqlstr::FuzzyString(Tmp->m_aFuzzyMap);
sqlstr::ClearString(Tmp->m_aFuzzyMap, sizeof(Tmp->m_aFuzzyMap));
sqlstr::FuzzyString(Tmp->m_aFuzzyMap, sizeof(Tmp->m_aFuzzyMap));

void *InfoThread = thread_init(ExecSqlFunc, new CSqlExecData(MapInfoThread, Tmp));
thread_detach(InfoThread);
Expand Down Expand Up @@ -783,7 +785,7 @@ bool CSqlScore::ShowTeamRankThread(CSqlServer* pSqlServer, const CSqlData *pGame
try
{
// check sort methode
char aBuf[600];
char aBuf[2400];
char aNames[2300];
aNames[0] = '\0';

Expand All @@ -810,13 +812,13 @@ bool CSqlScore::ShowTeamRankThread(CSqlServer* pSqlServer, const CSqlData *pGame

for(int Row = 0; Row < Rows; Row++)
{
strcat(aNames, pSqlServer->GetResults()->getString("Name").c_str());
str_append(aNames, pSqlServer->GetResults()->getString("Name").c_str(), sizeof(aNames));
pSqlServer->GetResults()->next();

if (Row < Rows - 2)
strcat(aNames, ", ");
str_append(aNames, ", ", sizeof(aNames));
else if (Row < Rows - 1)
strcat(aNames, " & ");
str_append(aNames, " & ", sizeof(aNames));
}

pSqlServer->GetResults()->first();
Expand Down Expand Up @@ -927,7 +929,7 @@ bool CSqlScore::ShowTeamTop5Thread(CSqlServer* pSqlServer, const CSqlData *pGame
try
{
// check sort methode
char aBuf[512];
char aBuf[2400];

pSqlServer->executeSql("SET @prev := NULL;");
pSqlServer->executeSql("SET @previd := NULL;");
Expand Down Expand Up @@ -972,12 +974,12 @@ bool CSqlScore::ShowTeamTop5Thread(CSqlServer* pSqlServer, const CSqlData *pGame
pSqlServer->GetResults()->first();
for(int Row = 0; Row < Rows; Row++)
{
strcat(aNames, pSqlServer->GetResults()->getString("Name").c_str());
str_append(aNames, pSqlServer->GetResults()->getString("Name").c_str(), sizeof(aNames));

if (Row < aCuts[CutPos] - 1)
strcat(aNames, ", ");
str_append(aNames, ", ", sizeof(aNames));
else if (Row < aCuts[CutPos])
strcat(aNames, " & ");
str_append(aNames, " & ", sizeof(aNames));

Time = (float)pSqlServer->GetResults()->getDouble("Time");
Rank = (float)pSqlServer->GetResults()->getInt("rank");
Expand Down
6 changes: 3 additions & 3 deletions src/game/version.h
Expand Up @@ -3,8 +3,8 @@
#ifndef GAME_VERSION_H
#define GAME_VERSION_H
#include "generated/nethash.cpp"
#define GAME_VERSION "0.6.3, 10.2.1"
#define GAME_VERSION "0.6.3, 10.3.5"
#define GAME_NETVERSION "0.6 626fce9a778df4d4"
static const char GAME_RELEASE_VERSION[8] = "10.2.1";
#define CLIENT_VERSIONNR 1002
static const char GAME_RELEASE_VERSION[8] = "10.3.5";
#define CLIENT_VERSIONNR 10035
#endif
13 changes: 13 additions & 0 deletions src/tools/confusables.cpp
@@ -0,0 +1,13 @@
#include <base/system.h>

int main(int argc, const char **argv) // ignore_convention
{
dbg_logger_stdout();
if(argc < 1 + 2)
{
dbg_msg("usage", "%s STR1 STR2", argv[0] ? argv[0] : "confusables");
return -1;
}
dbg_msg("conf", "not_confusable=%d", str_utf8_comp_confusable(argv[1], argv[2]));
return 0;
}