Merge remote-tracking branch 'origin/jetty-9.4.x'

This commit is contained in:
Greg Wilkins 2016-07-13 11:13:40 +10:00
commit 5b892f35c5
1 changed files with 7 additions and 1 deletions

View File

@ -24,6 +24,7 @@ import java.util.List;
import javax.net.ssl.SSLEngine;
import org.eclipse.jetty.http.HttpVersion;
import org.eclipse.jetty.io.AbstractConnection;
import org.eclipse.jetty.io.Connection;
import org.eclipse.jetty.io.EndPoint;
@ -110,10 +111,15 @@ public abstract class NegotiatingServerConnectionFactory extends AbstractConnect
}
}
// if default protocol is not set, then it is the first protocol given
// if default protocol is not set, then it is either HTTP/1.1 or
// the first protocol given
String dft = defaultProtocol;
if (dft == null && !negotiated.isEmpty())
{
if (negotiated.contains(HttpVersion.HTTP_1_1.asString()))
dft = HttpVersion.HTTP_1_1.asString();
dft = negotiated.get(0);
}
SSLEngine engine = null;
EndPoint ep = endPoint;