diff --git a/okhttp/src/main/java/com/squareup/okhttp/internal/http/RouteSelector.java b/okhttp/src/main/java/com/squareup/okhttp/internal/http/RouteSelector.java index 719313bd1b36..c5a24b564a05 100644 --- a/okhttp/src/main/java/com/squareup/okhttp/internal/http/RouteSelector.java +++ b/okhttp/src/main/java/com/squareup/okhttp/internal/http/RouteSelector.java @@ -243,7 +243,7 @@ private void resetNextInetSocketAddress(Proxy proxy) throws UnknownHostException String socketHost; int socketPort; if (proxy.type() == Proxy.Type.DIRECT) { - socketHost = uri.getHost(); + socketHost = address.getUriHost(); socketPort = getEffectivePort(uri); } else { SocketAddress proxyAddress = proxy.address();