summaryrefslogtreecommitdiffstats
path: root/extensions/common
diff options
context:
space:
mode:
authorxiyuan <xiyuan@chromium.org>2015-11-18 13:41:51 -0800
committerCommit bot <commit-bot@chromium.org>2015-11-18 21:42:41 +0000
commit2dcf0d1707d1029743635f419c0ca45ef6737dcd (patch)
tree005904ac7047855c7d0820dbbd7f3904c9f12e81 /extensions/common
parenta5a92367a5c0c58b3f61af77cbfe86973f8ea1f9 (diff)
downloadchromium_src-2dcf0d1707d1029743635f419c0ca45ef6737dcd.zip
chromium_src-2dcf0d1707d1029743635f419c0ca45ef6737dcd.tar.gz
chromium_src-2dcf0d1707d1029743635f419c0ca45ef6737dcd.tar.bz2
kiosk: Flush installed app files for real
Put back the change lost in UseSafeInstallation() during refactoring. BUG=555220 Review URL: https://codereview.chromium.org/1462463003 Cr-Commit-Position: refs/heads/master@{#360420}
Diffstat (limited to 'extensions/common')
-rw-r--r--extensions/common/file_util.cc10
1 files changed, 7 insertions, 3 deletions
diff --git a/extensions/common/file_util.cc b/extensions/common/file_util.cc
index 8ec4c99..763fa29 100644
--- a/extensions/common/file_util.cc
+++ b/extensions/common/file_util.cc
@@ -67,9 +67,13 @@ bool ValidateFilePath(const base::FilePath& path) {
// Returns true if the extension installation should flush all files and the
// directory.
bool UseSafeInstallation() {
- const char kFieldTrialName[] = "ExtensionUseSafeInstallation";
- const char kEnable[] = "Enable";
- return base::FieldTrialList::FindFullName(kFieldTrialName) == kEnable;
+ if (g_use_safe_installation == DEFAULT) {
+ const char kFieldTrialName[] = "ExtensionUseSafeInstallation";
+ const char kEnable[] = "Enable";
+ return base::FieldTrialList::FindFullName(kFieldTrialName) == kEnable;
+ }
+
+ return g_use_safe_installation == ENABLED;
}
enum FlushOneOrAllFiles {