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: net/socket_stream/socket_stream.cc

Issue 509563003: Remove implicit conversions from scoped_refptr to T* in net/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
« no previous file with comments | « net/server/http_server_unittest.cc ('k') | net/spdy/spdy_session_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 // TODO(ukai): code is similar with http_network_transaction.cc. We should 5 // TODO(ukai): code is similar with http_network_transaction.cc. We should
6 // think about ways to share code, if possible. 6 // think about ways to share code, if possible.
7 7
8 #include "net/socket_stream/socket_stream.h" 8 #include "net/socket_stream/socket_stream.h"
9 9
10 #include <set> 10 #include <set>
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 server_closed_(false), 113 server_closed_(false),
114 metrics_(new SocketStreamMetrics(url)), 114 metrics_(new SocketStreamMetrics(url)),
115 cookie_store_(cookie_store) { 115 cookie_store_(cookie_store) {
116 DCHECK(base::MessageLoop::current()) 116 DCHECK(base::MessageLoop::current())
117 << "The current base::MessageLoop must exist"; 117 << "The current base::MessageLoop must exist";
118 DCHECK(base::MessageLoopForIO::IsCurrent()) 118 DCHECK(base::MessageLoopForIO::IsCurrent())
119 << "The current base::MessageLoop must be TYPE_IO"; 119 << "The current base::MessageLoop must be TYPE_IO";
120 DCHECK(delegate_); 120 DCHECK(delegate_);
121 121
122 if (context_) { 122 if (context_) {
123 if (!cookie_store_) 123 if (!cookie_store_.get())
124 cookie_store_ = context_->cookie_store(); 124 cookie_store_ = context_->cookie_store();
125 125
126 net_log_ = BoundNetLog::Make( 126 net_log_ = BoundNetLog::Make(
127 context->net_log(), 127 context->net_log(),
128 NetLog::SOURCE_SOCKET_STREAM); 128 NetLog::SOURCE_SOCKET_STREAM);
129 129
130 net_log_.BeginEvent(NetLog::TYPE_REQUEST_ALIVE); 130 net_log_.BeginEvent(NetLog::TYPE_REQUEST_ALIVE);
131 } 131 }
132 } 132 }
133 133
(...skipping 1210 matching lines...) Expand 10 before | Expand all | Expand 10 after
1344 state && 1344 state &&
1345 state->ShouldSSLErrorsBeFatal( 1345 state->ShouldSSLErrorsBeFatal(
1346 url_.host(), 1346 url_.host(),
1347 SSLConfigService::IsSNIAvailable(context_->ssl_config_service())); 1347 SSLConfigService::IsSNIAvailable(context_->ssl_config_service()));
1348 1348
1349 delegate_->OnSSLCertificateError(this, ssl_info, fatal); 1349 delegate_->OnSSLCertificateError(this, ssl_info, fatal);
1350 return ERR_IO_PENDING; 1350 return ERR_IO_PENDING;
1351 } 1351 }
1352 1352
1353 CookieStore* SocketStream::cookie_store() const { 1353 CookieStore* SocketStream::cookie_store() const {
1354 return cookie_store_; 1354 return cookie_store_.get();
1355 } 1355 }
1356 1356
1357 } // namespace net 1357 } // namespace net
OLDNEW
« no previous file with comments | « net/server/http_server_unittest.cc ('k') | net/spdy/spdy_session_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698