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

Side by Side Diff: chrome/browser/devtools/devtools_network_transaction.cc

Issue 1422573008: Plumbing SSLPrivateKey (//net) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing extra tab. Created 5 years, 1 month 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 "chrome/browser/devtools/devtools_network_transaction.h" 5 #include "chrome/browser/devtools/devtools_network_transaction.h"
6 6
7 #include "chrome/browser/devtools/devtools_network_controller.h" 7 #include "chrome/browser/devtools/devtools_network_controller.h"
8 #include "chrome/browser/devtools/devtools_network_interceptor.h" 8 #include "chrome/browser/devtools/devtools_network_interceptor.h"
9 #include "net/base/net_errors.h" 9 #include "net/base/net_errors.h"
10 #include "net/base/upload_progress.h" 10 #include "net/base/upload_progress.h"
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 int DevToolsNetworkTransaction::RestartIgnoringLastError( 164 int DevToolsNetworkTransaction::RestartIgnoringLastError(
165 const net::CompletionCallback& callback) { 165 const net::CompletionCallback& callback) {
166 if (failed_) 166 if (failed_)
167 return net::ERR_INTERNET_DISCONNECTED; 167 return net::ERR_INTERNET_DISCONNECTED;
168 int rv = network_transaction_->RestartIgnoringLastError(proxy_callback_); 168 int rv = network_transaction_->RestartIgnoringLastError(proxy_callback_);
169 return SetupCallback(callback, rv, RESTART_IGNORING_LAST_ERROR); 169 return SetupCallback(callback, rv, RESTART_IGNORING_LAST_ERROR);
170 } 170 }
171 171
172 int DevToolsNetworkTransaction::RestartWithCertificate( 172 int DevToolsNetworkTransaction::RestartWithCertificate(
173 net::X509Certificate* client_cert, 173 net::X509Certificate* client_cert,
174 net::SSLPrivateKey* client_private_key,
174 const net::CompletionCallback& callback) { 175 const net::CompletionCallback& callback) {
175 if (failed_) 176 if (failed_)
176 return net::ERR_INTERNET_DISCONNECTED; 177 return net::ERR_INTERNET_DISCONNECTED;
177 int rv = network_transaction_->RestartWithCertificate( 178 int rv = network_transaction_->RestartWithCertificate(
178 client_cert, proxy_callback_); 179 client_cert, client_private_key, proxy_callback_);
179 return SetupCallback(callback, rv, RESTART_WITH_CERTIFICATE); 180 return SetupCallback(callback, rv, RESTART_WITH_CERTIFICATE);
180 } 181 }
181 182
182 int DevToolsNetworkTransaction::RestartWithAuth( 183 int DevToolsNetworkTransaction::RestartWithAuth(
183 const net::AuthCredentials& credentials, 184 const net::AuthCredentials& credentials,
184 const net::CompletionCallback& callback) { 185 const net::CompletionCallback& callback) {
185 if (failed_) 186 if (failed_)
186 return net::ERR_INTERNET_DISCONNECTED; 187 return net::ERR_INTERNET_DISCONNECTED;
187 int rv = network_transaction_->RestartWithAuth(credentials, proxy_callback_); 188 int rv = network_transaction_->RestartWithAuth(credentials, proxy_callback_);
188 return SetupCallback(callback, rv, RESTART_WITH_AUTH); 189 return SetupCallback(callback, rv, RESTART_WITH_AUTH);
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 } 284 }
284 285
285 void DevToolsNetworkTransaction::FireThrottledCallback() { 286 void DevToolsNetworkTransaction::FireThrottledCallback() {
286 DCHECK(!callback_.is_null()); 287 DCHECK(!callback_.is_null());
287 DCHECK(callback_type_ == READ || callback_type_ == START); 288 DCHECK(callback_type_ == READ || callback_type_ == START);
288 net::CompletionCallback callback = callback_; 289 net::CompletionCallback callback = callback_;
289 callback_.Reset(); 290 callback_.Reset();
290 callback_type_ = NONE; 291 callback_type_ = NONE;
291 callback.Run(throttled_result_); 292 callback.Run(throttled_result_);
292 } 293 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698