summaryrefslogtreecommitdiffstats
path: root/chrome/browser/profile.cc
diff options
context:
space:
mode:
authorrafaelw@chromium.org <rafaelw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-23 03:28:51 +0000
committerrafaelw@chromium.org <rafaelw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-23 03:28:51 +0000
commitc931db6d8adbf334c86e31714e2897bc2e9db08a (patch)
treecf83d11e8e00e45a4733ad62c1a38f0925d8dd8c /chrome/browser/profile.cc
parentd146b8311c38186872d2be3764e2c2d66827107f (diff)
downloadchromium_src-c931db6d8adbf334c86e31714e2897bc2e9db08a.zip
chromium_src-c931db6d8adbf334c86e31714e2897bc2e9db08a.tar.gz
chromium_src-c931db6d8adbf334c86e31714e2897bc2e9db08a.tar.bz2
Don't inject content scripts into incognito browsers.
This patch prevents content scripts from being injected into incognito profile tabs by only injecting into the same profile in which the extension is running. BUG=21392 TEST=Load chrome/test/data/extensions/api/incognito_no_script and open any url in incognito browser. No page titles should be modified to "modified". Review URL: http://codereview.chromium.org/502079 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35203 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/profile.cc')
-rw-r--r--chrome/browser/profile.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/chrome/browser/profile.cc b/chrome/browser/profile.cc
index 51990a0..3231ede2 100644
--- a/chrome/browser/profile.cc
+++ b/chrome/browser/profile.cc
@@ -250,7 +250,7 @@ class OffTheRecordProfileImpl : public Profile,
}
virtual UserScriptMaster* GetUserScriptMaster() {
- return profile_->GetUserScriptMaster();
+ return NULL;
}
virtual ExtensionDevToolsManager* GetExtensionDevToolsManager() {
@@ -667,7 +667,7 @@ void ProfileImpl::InitExtensions() {
FilePath script_dir; // Don't look for user scripts in any directory.
// TODO(aa): We should just remove this functionality,
// since it isn't used anymore.
- user_script_master_ = new UserScriptMaster(script_dir);
+ user_script_master_ = new UserScriptMaster(script_dir, this);
extensions_service_ = new ExtensionsService(
this,