Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: extensions/browser/api/cast_channel/cast_socket.cc

Issue 1376473003: Notify NQE of TCP RTT values (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed bengr comments Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "extensions/browser/api/cast_channel/cast_socket.h" 5 #include "extensions/browser/api/cast_channel/cast_socket.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 #include <string.h> 8 #include <string.h>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 return keep_alive_; 168 return keep_alive_;
169 } 169 }
170 170
171 bool CastSocketImpl::audio_only() const { 171 bool CastSocketImpl::audio_only() const {
172 return audio_only_; 172 return audio_only_;
173 } 173 }
174 174
175 scoped_ptr<net::TCPClientSocket> CastSocketImpl::CreateTcpSocket() { 175 scoped_ptr<net::TCPClientSocket> CastSocketImpl::CreateTcpSocket() {
176 net::AddressList addresses(ip_endpoint_); 176 net::AddressList addresses(ip_endpoint_);
177 return scoped_ptr<net::TCPClientSocket>( 177 return scoped_ptr<net::TCPClientSocket>(
178 new net::TCPClientSocket(addresses, net_log_, net_log_source_)); 178 new net::TCPClientSocket(addresses, nullptr, net_log_, net_log_source_));
179 // Options cannot be set on the TCPClientSocket yet, because the 179 // Options cannot be set on the TCPClientSocket yet, because the
180 // underlying platform socket will not be created until Bind() 180 // underlying platform socket will not be created until Bind()
181 // or Connect() is called. 181 // or Connect() is called.
182 } 182 }
183 183
184 scoped_ptr<net::SSLClientSocket> CastSocketImpl::CreateSslSocket( 184 scoped_ptr<net::SSLClientSocket> CastSocketImpl::CreateSslSocket(
185 scoped_ptr<net::StreamSocket> socket) { 185 scoped_ptr<net::StreamSocket> socket) {
186 net::SSLConfig ssl_config; 186 net::SSLConfig ssl_config;
187 cert_verifier_ = make_scoped_ptr(new FakeCertVerifier); 187 cert_verifier_ = make_scoped_ptr(new FakeCertVerifier);
188 transport_security_state_.reset(new net::TransportSecurityState); 188 transport_security_state_.reset(new net::TransportSecurityState);
(...skipping 425 matching lines...) Expand 10 before | Expand all | Expand 10 after
614 VLOG_WITH_CONNECTION(1) << "SetErrorState " << error_state; 614 VLOG_WITH_CONNECTION(1) << "SetErrorState " << error_state;
615 DCHECK_EQ(CHANNEL_ERROR_NONE, error_state_); 615 DCHECK_EQ(CHANNEL_ERROR_NONE, error_state_);
616 error_state_ = error_state; 616 error_state_ = error_state;
617 logger_->LogSocketErrorState(channel_id_, ErrorStateToProto(error_state_)); 617 logger_->LogSocketErrorState(channel_id_, ErrorStateToProto(error_state_));
618 delegate_->OnError(error_state_); 618 delegate_->OnError(error_state_);
619 } 619 }
620 } // namespace cast_channel 620 } // namespace cast_channel
621 } // namespace api 621 } // namespace api
622 } // namespace extensions 622 } // namespace extensions
623 #undef VLOG_WITH_CONNECTION 623 #undef VLOG_WITH_CONNECTION
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698