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

Unified Diff: chrome/browser/extensions/extension_special_storage_policy.cc

Issue 13209004: Add a flag to override unlimitedStorage quota for any origins. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | « no previous file | content/public/common/content_switches.h » ('j') | content/public/common/content_switches.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/extension_special_storage_policy.cc
diff --git a/chrome/browser/extensions/extension_special_storage_policy.cc b/chrome/browser/extensions/extension_special_storage_policy.cc
index e23964185b098be1c800ebbaf6137a4bcfe862fa..12ab123ee5f2753619d3a5452ab7ea6f69ad5912 100644
--- a/chrome/browser/extensions/extension_special_storage_policy.cc
+++ b/chrome/browser/extensions/extension_special_storage_policy.cc
@@ -5,6 +5,7 @@
#include "chrome/browser/extensions/extension_special_storage_policy.h"
#include "base/bind.h"
+#include "base/command_line.h"
#include "base/logging.h"
#include "base/stl_util.h"
#include "base/utf_string_conversions.h"
@@ -14,6 +15,7 @@
#include "chrome/common/extensions/extension.h"
#include "chrome/common/url_constants.h"
#include "content/public/browser/browser_thread.h"
+#include "content/public/common/content_switches.h"
#include "extensions/common/constants.h"
using content::BrowserThread;
@@ -33,6 +35,9 @@ bool ExtensionSpecialStoragePolicy::IsStorageProtected(const GURL& origin) {
}
bool ExtensionSpecialStoragePolicy::IsStorageUnlimited(const GURL& origin) {
+ if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kUnlimitedStorage))
+ return true;
+
base::AutoLock locker(lock_);
return unlimited_extensions_.Contains(origin);
}
« no previous file with comments | « no previous file | content/public/common/content_switches.h » ('j') | content/public/common/content_switches.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698