| Index: net/http/http_stream_factory_impl_job.cc
|
| diff --git a/net/http/http_stream_factory_impl_job.cc b/net/http/http_stream_factory_impl_job.cc
|
| index 8729dfbba293736b550fd70027c9852804520ffa..78e5498a0f4c675da316461ff1f8b156f6d36ae7 100644
|
| --- a/net/http/http_stream_factory_impl_job.cc
|
| +++ b/net/http/http_stream_factory_impl_job.cc
|
| @@ -91,6 +91,7 @@ HttpStreamFactoryImpl::Job::Job(HttpStreamFactoryImpl* stream_factory,
|
| using_ssl_(false),
|
| using_spdy_(false),
|
| using_quic_(false),
|
| + using_quic_proxy_(false),
|
| quic_request_(session_->quic_stream_factory()),
|
| using_existing_quic_session_(false),
|
| spdy_certificate_error_(OK),
|
| @@ -671,10 +672,15 @@ int HttpStreamFactoryImpl::Job::DoResolveProxyComplete(int result) {
|
|
|
| if (result == OK) {
|
| // Remove unsupported proxies from the list.
|
| - proxy_info_.RemoveProxiesWithoutScheme(
|
| - ProxyServer::SCHEME_DIRECT | ProxyServer::SCHEME_QUIC |
|
| - ProxyServer::SCHEME_HTTP | ProxyServer::SCHEME_HTTPS |
|
| - ProxyServer::SCHEME_SOCKS4 | ProxyServer::SCHEME_SOCKS5);
|
| + int supported_proxies =
|
| + ProxyServer::SCHEME_DIRECT | ProxyServer::SCHEME_HTTP |
|
| + ProxyServer::SCHEME_HTTPS | ProxyServer::SCHEME_SOCKS4 |
|
| + ProxyServer::SCHEME_SOCKS5;
|
| +
|
| + if (session_->params().enable_quic_for_proxies)
|
| + supported_proxies |= ProxyServer::SCHEME_QUIC;
|
| +
|
| + proxy_info_.RemoveProxiesWithoutScheme(supported_proxies);
|
|
|
| if (proxy_info_.is_empty()) {
|
| // No proxies/direct to choose from. This happens when we don't support
|
| @@ -747,11 +753,16 @@ int HttpStreamFactoryImpl::Job::DoInitConnection() {
|
| if (ShouldForceQuic())
|
| using_quic_ = true;
|
|
|
| - if (proxy_info_.is_quic())
|
| + if (using_quic_)
|
| + DCHECK(session_->params().enable_quic);
|
| +
|
| + if (proxy_info_.is_quic()) {
|
| using_quic_ = true;
|
| + using_quic_proxy_ = true;
|
| + DCHECK(session_->params().enable_quic_for_proxies);
|
| + }
|
|
|
| if (using_quic_) {
|
| - DCHECK(session_->params().enable_quic);
|
| if (proxy_info_.is_quic() && !request_info_.url.SchemeIs("http")) {
|
| NOTREACHED();
|
| // TODO(rch): support QUIC proxies for HTTPS urls.
|
|
|