| 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 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 881 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 892 } | 892 } |
| 893 return result; | 893 return result; |
| 894 } | 894 } |
| 895 | 895 |
| 896 next_state_ = STATE_WAIT_FOR_JOB; | 896 next_state_ = STATE_WAIT_FOR_JOB; |
| 897 return OK; | 897 return OK; |
| 898 } | 898 } |
| 899 | 899 |
| 900 bool HttpStreamFactoryImpl::Job::ShouldForceQuic() const { | 900 bool HttpStreamFactoryImpl::Job::ShouldForceQuic() const { |
| 901 return session_->params().enable_quic && | 901 return session_->params().enable_quic && |
| 902 session_->params().origin_to_force_quic_on.Equals(server_) && | 902 ContainsKey(session_->params().origins_to_force_quic_on, server_) && |
| 903 proxy_info_.is_direct() && origin_url_.SchemeIs("https"); | 903 proxy_info_.is_direct() && origin_url_.SchemeIs("https"); |
| 904 } | 904 } |
| 905 | 905 |
| 906 int HttpStreamFactoryImpl::Job::DoWaitForJob() { | 906 int HttpStreamFactoryImpl::Job::DoWaitForJob() { |
| 907 if (!blocking_job_ && wait_time_.is_zero()) { | 907 if (!blocking_job_ && wait_time_.is_zero()) { |
| 908 // There is no |blocking_job_| and there is no |wait_time_|. | 908 // There is no |blocking_job_| and there is no |wait_time_|. |
| 909 next_state_ = STATE_INIT_CONNECTION; | 909 next_state_ = STATE_INIT_CONNECTION; |
| 910 return OK; | 910 return OK; |
| 911 } | 911 } |
| 912 | 912 |
| (...skipping 878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1791 if (connection_->socket()) { | 1791 if (connection_->socket()) { |
| 1792 ConnectionAttempts socket_attempts; | 1792 ConnectionAttempts socket_attempts; |
| 1793 connection_->socket()->GetConnectionAttempts(&socket_attempts); | 1793 connection_->socket()->GetConnectionAttempts(&socket_attempts); |
| 1794 request_->AddConnectionAttempts(socket_attempts); | 1794 request_->AddConnectionAttempts(socket_attempts); |
| 1795 } else { | 1795 } else { |
| 1796 request_->AddConnectionAttempts(connection_->connection_attempts()); | 1796 request_->AddConnectionAttempts(connection_->connection_attempts()); |
| 1797 } | 1797 } |
| 1798 } | 1798 } |
| 1799 | 1799 |
| 1800 } // namespace net | 1800 } // namespace net |
| OLD | NEW |