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

Unified Diff: content/renderer/media/peer_connection_identity_service.cc

Issue 22640017: Passing NULL PeerConnectionIdentityService to Libjingle when Chrome is using openssl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 4 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
Index: content/renderer/media/peer_connection_identity_service.cc
diff --git a/content/renderer/media/peer_connection_identity_service.cc b/content/renderer/media/peer_connection_identity_service.cc
index f7bc85681022c8cd4accc626bbc59999eda2d6e9..904eb4128c318d6d60f53e72a05b382c9d420b0d 100644
--- a/content/renderer/media/peer_connection_identity_service.cc
+++ b/content/renderer/media/peer_connection_identity_service.cc
@@ -9,8 +9,17 @@
namespace content {
-PeerConnectionIdentityService::PeerConnectionIdentityService(const GURL& origin)
- : origin_(origin), pending_observer_(NULL), pending_request_id_(0) {}
+PeerConnectionIdentityService* PeerConnectionIdentityService::Create(
+ const GURL& origin) {
+// The crypto APIs needed for generating identities are not implenented for
+// OPENSSL yet (crbug/91512). So returning NULL in that case.
+// TODO(jiayl): remove the #if once the crypto APIs are implemented for OPENSSL.
+#if defined(USE_OPENSSL)
+ return NULL;
+#else
+ return new PeerConnectionIdentityService(origin);
+#endif // defined(USE_OPENSSL)
+}
PeerConnectionIdentityService::~PeerConnectionIdentityService() {
if (pending_observer_)
@@ -39,6 +48,9 @@ bool PeerConnectionIdentityService::RequestIdentity(
return true;
}
+PeerConnectionIdentityService::PeerConnectionIdentityService(const GURL& origin)
+ : origin_(origin), pending_observer_(NULL), pending_request_id_(0) {}
+
void PeerConnectionIdentityService::OnIdentityReady(
const std::string& certificate,
const std::string& private_key) {

Powered by Google App Engine
This is Rietveld 408576698