summaryrefslogtreecommitdiff
path: root/src/network/core/tcp_http.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/network/core/tcp_http.cpp')
-rw-r--r--src/network/core/tcp_http.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/network/core/tcp_http.cpp b/src/network/core/tcp_http.cpp
index ee74c4507..99eca1cb7 100644
--- a/src/network/core/tcp_http.cpp
+++ b/src/network/core/tcp_http.cpp
@@ -203,11 +203,7 @@ int NetworkHTTPSocketHandler::HandleHeader()
*url = '\0';
- /* Fetch the hostname, and possible port number. */
- const char *port = nullptr;
- ParseConnectionString(&port, hname);
-
- NetworkAddress address(hname, port == nullptr ? 80 : atoi(port));
+ NetworkAddress address = ParseConnectionString(hname, 80);
/* Restore the URL. */
*url = '/';