You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by ti...@apache.org on 2020/06/12 22:46:34 UTC
[maven-surefire] branch macos-ipv4 updated: localhost
This is an automated email from the ASF dual-hosted git repository.
tibordigana pushed a commit to branch macos-ipv4
in repository https://gitbox.apache.org/repos/asf/maven-surefire.git
The following commit(s) were added to refs/heads/macos-ipv4 by this push:
new 65c2de5 localhost
65c2de5 is described below
commit 65c2de5880e61cdbddda52007648fa9aaf9fbb7d
Author: tibordigana <ti...@apache.org>
AuthorDate: Sat Jun 13 00:46:24 2020 +0200
localhost
---
.../maven/plugin/surefire/extensions/SurefireForkChannel.java | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/extensions/SurefireForkChannel.java b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/extensions/SurefireForkChannel.java
index cb89dd5..849931e 100644
--- a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/extensions/SurefireForkChannel.java
+++ b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/extensions/SurefireForkChannel.java
@@ -83,10 +83,11 @@ final class SurefireForkChannel extends ForkChannel
super( arguments );
server = open( withThreadPool( THREAD_POOL ) );
setTrueOptions( SO_REUSEADDR, TCP_NODELAY, SO_KEEPALIVE );
- server.bind( new InetSocketAddress( InetAddress.getByAddress( InetAddress.getLocalHost().getAddress() ),
- 0 ), 1 );
+ // InetAddress ip = InetAddress.getByAddress( InetAddress.getLocalHost().getAddress() );
+ InetAddress ip = InetAddress.getLocalHost();
+ server.bind( new InetSocketAddress( ip, 0 ), 1 );
InetSocketAddress localAddress = (InetSocketAddress) server.getLocalAddress();
- localHost = InetAddress.getLocalHost().getHostAddress(); // localAddress.getHostString();
+ localHost = localAddress.getHostString(); // InetAddress.getLocalHost().getHostAddress();
localPort = localAddress.getPort();
}