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

Unified Diff: webrtc/p2p/base/transportcontroller.cc

Issue 1802013002: A bunch of interfaces: Return scoped_ptr<SSLCertificate> (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: less auto Created 4 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/p2p/base/transportcontroller.h ('k') | webrtc/p2p/base/transportcontroller_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/p2p/base/transportcontroller.cc
diff --git a/webrtc/p2p/base/transportcontroller.cc b/webrtc/p2p/base/transportcontroller.cc
index 128d2fc656406d75b7b094baf1e8a57cd32513e1..708c60f9df5471f4efad73a6d259a0dd39210162 100644
--- a/webrtc/p2p/base/transportcontroller.cc
+++ b/webrtc/p2p/base/transportcontroller.cc
@@ -86,12 +86,11 @@ bool TransportController::GetLocalCertificate(
transport_name, certificate));
}
-bool TransportController::GetRemoteSSLCertificate(
- const std::string& transport_name,
- rtc::SSLCertificate** cert) {
- return worker_thread_->Invoke<bool>(
- rtc::Bind(&TransportController::GetRemoteSSLCertificate_w, this,
- transport_name, cert));
+rtc::scoped_ptr<rtc::SSLCertificate>
+TransportController::GetRemoteSSLCertificate(
+ const std::string& transport_name) {
+ return worker_thread_->Invoke<rtc::scoped_ptr<rtc::SSLCertificate>>(rtc::Bind(
+ &TransportController::GetRemoteSSLCertificate_w, this, transport_name));
}
bool TransportController::SetLocalTransportDescription(
@@ -395,17 +394,17 @@ bool TransportController::GetLocalCertificate_w(
return t->GetLocalCertificate(certificate);
}
-bool TransportController::GetRemoteSSLCertificate_w(
- const std::string& transport_name,
- rtc::SSLCertificate** cert) {
+rtc::scoped_ptr<rtc::SSLCertificate>
+TransportController::GetRemoteSSLCertificate_w(
+ const std::string& transport_name) {
RTC_DCHECK(worker_thread_->IsCurrent());
Transport* t = GetTransport_w(transport_name);
if (!t) {
- return false;
+ return nullptr;
}
- return t->GetRemoteSSLCertificate(cert);
+ return t->GetRemoteSSLCertificate();
}
bool TransportController::SetLocalTransportDescription_w(
« no previous file with comments | « webrtc/p2p/base/transportcontroller.h ('k') | webrtc/p2p/base/transportcontroller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698