Skip to content

Commit 8c7a4e0

Browse files
committed
[grid] Only check hostname for connections that use host names
1 parent 6dc1342 commit 8c7a4e0

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

java/server/src/org/openqa/selenium/events/zeromq/UnboundZmqEventBus.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,13 @@ public boolean isReady() {
158158

159159
private boolean isSubAddressIPv6(String connection) {
160160
try {
161-
return InetAddress.getByName(new URI(connection).getHost()) instanceof Inet6Address;
161+
URI uri = new URI(connection);
162+
163+
if ("inproc".equals(uri.getScheme())) {
164+
return false;
165+
}
166+
167+
return InetAddress.getByName(uri.getHost()) instanceof Inet6Address;
162168
} catch (UnknownHostException | URISyntaxException e) {
163169
LOG.log(Level.WARNING, String.format("Could not determine if the address %s is IPv6 or IPv4", connection), e);
164170
}

0 commit comments

Comments
 (0)