Skip to content

Commit e92702c

Browse files
Strip server name's spaces from beginning and end (#3805)
1 parent 353b6c6 commit e92702c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Server/mods/deathmatch/logic/CMainConfig.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,9 @@ bool CMainConfig::Load()
133133
return false;
134134
}
135135

136+
// Strip spaces from beginning and end of server name
137+
m_strServerName = SString(m_strServerName).TrimStart(" ").TrimEnd(" ");
138+
136139
// Grab the forced server ip(s)
137140
GetString(m_pRootNode, "serverip", m_strServerIP);
138141
m_strServerIP = SString(m_strServerIP).Replace(" ", "");

0 commit comments

Comments
 (0)