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

Unified Diff: components/policy/core/common/config_dir_policy_loader.cc

Issue 1304843004: Add source column to chrome://policy showing the origins of policies. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed another test. Created 5 years, 3 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
Index: components/policy/core/common/config_dir_policy_loader.cc
diff --git a/components/policy/core/common/config_dir_policy_loader.cc b/components/policy/core/common/config_dir_policy_loader.cc
index b39d8385bbfca48e5a653a9edf7862bf74fc27bf..b81bfa99269badef3534e6e5f63a633f2ef215a2 100644
--- a/components/policy/core/common/config_dir_policy_loader.cc
+++ b/components/policy/core/common/config_dir_policy_loader.cc
@@ -18,6 +18,7 @@
#include "base/stl_util.h"
#include "components/policy/core/common/policy_bundle.h"
#include "components/policy/core/common/policy_load_status.h"
+#include "components/policy/core/common/policy_types.h"
namespace policy {
@@ -165,7 +166,8 @@ void ConfigDirPolicyLoader::LoadFromPath(const base::FilePath& path,
// Add chrome policy.
PolicyMap policy_map;
- policy_map.LoadFrom(dictionary_value, level, scope_);
+ policy_map.LoadFrom(dictionary_value, level, scope_,
+ POLICY_SOURCE_PLATFORM);
bundle->Get(PolicyNamespace(POLICY_DOMAIN_CHROME, std::string()))
.MergeFrom(policy_map);
}
@@ -215,7 +217,7 @@ void ConfigDirPolicyLoader::Merge3rdPartyPolicy(
}
PolicyMap policy;
- policy.LoadFrom(policy_dictionary, level, scope_);
+ policy.LoadFrom(policy_dictionary, level, scope_, POLICY_SOURCE_PLATFORM);
bundle->Get(PolicyNamespace(domain, components_it.key()))
.MergeFrom(policy);
}

Powered by Google App Engine
This is Rietveld 408576698