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

Unified Diff: content/browser/renderer_host/media/media_stream_manager.cc

Issue 12150003: Remove extension scheme check in MediaStreamManager. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/media/media_stream_manager.cc
diff --git a/content/browser/renderer_host/media/media_stream_manager.cc b/content/browser/renderer_host/media/media_stream_manager.cc
index 0db4d656c2f74b20779d2a318a40e5c010653243..3c109b012cbee82a03c53d62538ef339cc669367 100644
--- a/content/browser/renderer_host/media/media_stream_manager.cc
+++ b/content/browser/renderer_host/media/media_stream_manager.cc
@@ -32,10 +32,6 @@
#include "base/win/scoped_com_initializer.h"
#endif
-namespace {
-const char kExtensionScheme[] = "chrome-extension";
-} // namespace
-
namespace content {
// Creates a random label used to identify requests.
@@ -245,18 +241,17 @@ std::string MediaStreamManager::GenerateStreamForDevice(
int target_render_process_id = -1;
int target_render_view_id = -1;
- // We will post the request to the target render view, not the source (i.e.
- // source is an extension, and target is the tab we want to capture).
+ // We will post the request to the render view that is the target of the
+ // capture.
bool has_valid_device_id = WebContentsCaptureUtil::ExtractTabCaptureTarget(
device_id, &target_render_process_id, &target_render_view_id);
if (!has_valid_device_id ||
- !security_origin.SchemeIs(kExtensionScheme) ||
(options.audio_type != MEDIA_TAB_AUDIO_CAPTURE &&
options.audio_type != MEDIA_NO_SERVICE) ||
(options.video_type != MEDIA_TAB_VIDEO_CAPTURE &&
options.video_type != MEDIA_NO_SERVICE)) {
- LOG(ERROR) << "Invalid request or used tab capture outside extension API.";
+ LOG(ERROR) << "Invalid request.";
return std::string();
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698