Remove CNetClient::SetupServerData

It has to be called before `SetupConnection` is called. Now the
server-data is setup during the constructor.
When connecting using the lobby, the data isn't known at construction
time. Then it is done at the start of  `TryToConnectWithSTUN`.
This commit is contained in:
phosit
2026-03-02 21:35:28 +01:00
parent 19c6977872
commit 578aea3b09
5 changed files with 34 additions and 44 deletions
+1 -2
View File
@@ -862,8 +862,7 @@ bool XmppClient::handleIq(const gloox::IQ& iq)
return true;
}
g_NetClient->SetupServerData(cd->m_Ip, stoi(cd->m_Port));
g_NetClient->TryToConnectWithSTUN(iq.from().full(), !cd->m_IsLocalIP.empty());
g_NetClient->TryToConnectWithSTUN(cd->m_Ip, stoi(cd->m_Port), iq.from().full(), !cd->m_IsLocalIP.empty());
}
if (gq)
{