From 6fad24aef2d57b92e563bab2d7f70870c0ae6edf Mon Sep 17 00:00:00 2001 From: Oleg Kalnichevski Date: Tue, 28 May 2013 12:14:19 +0000 Subject: [PATCH] HTTPCLIENT-1357: Connection upgrade operation does not resolve default port (-1) to a scheme default value which can lead to a InvalidArgumentException on some platforms git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1486900 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/http/impl/conn/DefaultClientConnectionOperator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnectionOperator.java b/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnectionOperator.java index 4053d8058..85bed47d5 100644 --- a/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnectionOperator.java +++ b/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnectionOperator.java @@ -218,7 +218,7 @@ public class DefaultClientConnectionOperator implements ClientConnectionOperator Socket sock; try { sock = lsf.createLayeredSocket( - conn.getSocket(), target.getHostName(), target.getPort(), params); + conn.getSocket(), target.getHostName(), schm.resolvePort(target.getPort()), params); } catch (final ConnectException ex) { throw new HttpHostConnectException(target, ex); }