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

Unified Diff: content/renderer/render_view_impl.cc

Issue 9369022: disable media stream creation when enable_webrtc=0 (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: code review Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/media/media_stream_impl_stub.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_view_impl.cc
===================================================================
--- content/renderer/render_view_impl.cc (revision 121195)
+++ content/renderer/render_view_impl.cc (working copy)
@@ -504,8 +504,10 @@
p2p_socket_dispatcher_ = new content::P2PSocketDispatcher(this);
#endif
+#if defined(ENABLE_WEBRTC)
if (!media_stream_dispatcher_)
media_stream_dispatcher_ = new MediaStreamDispatcher(this);
+#endif
new MHTMLGenerator(this);
#if defined(OS_MACOSX)
@@ -622,6 +624,8 @@
if (!cmd_line->HasSwitch(switches::kEnableMediaStream))
return NULL;
EnsureMediaStreamImpl();
+ if (!media_stream_impl_.get())
+ return NULL;
return media_stream_impl_->CreatePeerConnectionHandler(client);
}
@@ -3146,6 +3150,7 @@
p2p_socket_dispatcher_ = new content::P2PSocketDispatcher(this);
#endif
+#if defined(ENABLE_WEBRTC)
if (!media_stream_dispatcher_)
media_stream_dispatcher_ = new MediaStreamDispatcher(this);
@@ -3157,6 +3162,7 @@
RenderThreadImpl::current()->video_capture_impl_manager(),
factory);
}
+#endif
}
void RenderViewImpl::didChangeContentsSize(WebFrame* frame,
« no previous file with comments | « content/renderer/media/media_stream_impl_stub.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698