summaryrefslogtreecommitdiff
path: root/src/openttd.cpp
diff options
context:
space:
mode:
authorrubidium42 <rubidium@openttd.org>2021-04-27 10:56:26 +0200
committerCharles Pigott <charlespigott@googlemail.com>2021-04-27 18:17:34 +0100
commitcbad518bf3c7e6d05b62d8c1d063b89d974e5f33 (patch)
tree4c48ee1f10f23ec4a27e82d3db110de54db31480 /src/openttd.cpp
parentcf8c1aa860e05e696f9829e3b031a22ca82781ef (diff)
downloadopenttd-cbad518bf3c7e6d05b62d8c1d063b89d974e5f33.tar.xz
Codechange: [Network] Do not leak os_abstraction.h via network_func
Diffstat (limited to 'src/openttd.cpp')
-rw-r--r--src/openttd.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/openttd.cpp b/src/openttd.cpp
index b204ca5a2..016d48287 100644
--- a/src/openttd.cpp
+++ b/src/openttd.cpp
@@ -495,7 +495,7 @@ struct AfterNewGRFScan : NewGRFScanCallback {
LoadIntroGame();
_switch_mode = SM_NONE;
- NetworkClientConnectGame(NetworkAddress(network_conn, rport), join_as, join_server_password, join_company_password);
+ NetworkClientConnectGame(network_conn, rport, join_as, join_server_password, join_company_password);
}
/* After the scan we're not used anymore. */
@@ -779,7 +779,7 @@ int openttd_main(int argc, char *argv[])
ParseConnectionString(&port, debuglog_conn);
if (port != nullptr) rport = atoi(port);
- NetworkStartDebugLog(NetworkAddress(debuglog_conn, rport));
+ NetworkStartDebugLog(debuglog_conn, rport);
}
if (!HandleBootstrap()) {
@@ -1491,7 +1491,7 @@ void GameLoop()
if (_network_reconnect > 0 && --_network_reconnect == 0) {
/* This means that we want to reconnect to the last host
* We do this here, because it means that the network is really closed */
- NetworkClientConnectGame(NetworkAddress(_settings_client.network.last_host, _settings_client.network.last_port), COMPANY_SPECTATOR);
+ NetworkClientConnectGame(_settings_client.network.last_host, _settings_client.network.last_port, COMPANY_SPECTATOR);
}
/* Singleplayer */
StateGameLoop();