Skip to content

Commit 9d13f59

Browse files
authored
Actually print the port that was bound, instead of the one from the config (#644)
In the case of binding to port 0, this will print the actually bound port, instead of the `0` that's in the configuration file. (cherry picked from commit d8a9c52)
1 parent b3dfc47 commit 9d13f59

File tree

1 file changed

+1
-1
lines changed
  • common/src/main/java/de/bluecolored/bluemap/common/web/http

1 file changed

+1
-1
lines changed

common/src/main/java/de/bluecolored/bluemap/common/web/http/Server.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public void bind(SocketAddress address) throws IOException {
5555
this.server.add(server);
5656

5757
if (checkIfBoundToAllInterfaces(address)) {
58-
Logger.global.logInfo("WebServer bound to all network interfaces on port " + ((InetSocketAddress) address).getPort());
58+
Logger.global.logInfo("WebServer bound to all network interfaces on port " + ((InetSocketAddress) server.getLocalAddress()).getPort());
5959
} else {
6060
Logger.global.logInfo("WebServer bound to: " + server.getLocalAddress());
6161
}

0 commit comments

Comments
 (0)