OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "net/http/http_stream_factory_impl_job.h" | 5 #include "net/http/http_stream_factory_impl_job.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 722 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
733 if (proxy_info_.is_quic() && !request_info_.url.SchemeIs("http")) { | 733 if (proxy_info_.is_quic() && !request_info_.url.SchemeIs("http")) { |
734 NOTREACHED(); | 734 NOTREACHED(); |
735 // TODO(rch): support QUIC proxies for HTTPS urls. | 735 // TODO(rch): support QUIC proxies for HTTPS urls. |
736 return ERR_NOT_IMPLEMENTED; | 736 return ERR_NOT_IMPLEMENTED; |
737 } | 737 } |
738 HostPortPair destination = proxy_info_.is_quic() ? | 738 HostPortPair destination = proxy_info_.is_quic() ? |
739 proxy_info_.proxy_server().host_port_pair() : origin_; | 739 proxy_info_.proxy_server().host_port_pair() : origin_; |
740 next_state_ = STATE_INIT_CONNECTION_COMPLETE; | 740 next_state_ = STATE_INIT_CONNECTION_COMPLETE; |
741 bool secure_quic = using_ssl_ || proxy_info_.is_quic(); | 741 bool secure_quic = using_ssl_ || proxy_info_.is_quic(); |
742 int rv = quic_request_.Request( | 742 int rv = quic_request_.Request( |
743 destination, secure_quic, request_info_.privacy_mode, | 743 destination, secure_quic, request_info_.method, net_log_, io_callback_); |
744 request_info_.method, net_log_, io_callback_); | |
745 if (rv != OK) { | 744 if (rv != OK) { |
746 // OK, there's no available QUIC session. Let |waiting_job_| resume | 745 // OK, there's no available QUIC session. Let |waiting_job_| resume |
747 // if it's paused. | 746 // if it's paused. |
748 if (waiting_job_) { | 747 if (waiting_job_) { |
749 waiting_job_->Resume(this); | 748 waiting_job_->Resume(this); |
750 waiting_job_ = NULL; | 749 waiting_job_ = NULL; |
751 } | 750 } |
752 } | 751 } |
753 return rv; | 752 return rv; |
754 } | 753 } |
(...skipping 701 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1456 (net::LOAD_MAIN_FRAME | net::LOAD_SUB_FRAME | net::LOAD_PREFETCH | | 1455 (net::LOAD_MAIN_FRAME | net::LOAD_SUB_FRAME | net::LOAD_PREFETCH | |
1457 net::LOAD_IS_DOWNLOAD)) { | 1456 net::LOAD_IS_DOWNLOAD)) { |
1458 // Avoid pipelining resources that may be streamed for a long time. | 1457 // Avoid pipelining resources that may be streamed for a long time. |
1459 return false; | 1458 return false; |
1460 } | 1459 } |
1461 return stream_factory_->http_pipelined_host_pool_.IsKeyEligibleForPipelining( | 1460 return stream_factory_->http_pipelined_host_pool_.IsKeyEligibleForPipelining( |
1462 *http_pipelining_key_.get()); | 1461 *http_pipelining_key_.get()); |
1463 } | 1462 } |
1464 | 1463 |
1465 } // namespace net | 1464 } // namespace net |
OLD | NEW |