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

Unified Diff: remoting/host/policy_watcher.h

Issue 966433002: Malformed PortRange or ThirdPartyAuthConfig trigger OnPolicyError. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing a Windows-specific, pre-processor-related build break. Created 5 years, 10 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 | « remoting/host/it2me/it2me_host.cc ('k') | remoting/host/policy_watcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/policy_watcher.h
diff --git a/remoting/host/policy_watcher.h b/remoting/host/policy_watcher.h
index 6b690ab2bc62d4a72453cf8fe4ed9caceb295082..1cd5833009858accb246e5d394b84cda04407a9b 100644
--- a/remoting/host/policy_watcher.h
+++ b/remoting/host/policy_watcher.h
@@ -80,13 +80,20 @@ class PolicyWatcher : public policy::PolicyService::Observer,
private:
friend class PolicyWatcherTest;
- // Takes the policy dictionary from the OS specific store and extracts the
- // relevant policies.
- void UpdatePolicies(const base::DictionaryValue* new_policy);
-
// Gets Chromoting schema stored inside |owned_schema_registry_|.
const policy::Schema* GetPolicySchema() const;
+ // Simplifying wrapper around Schema::Normalize.
+ // - Returns false if |dict| is invalid (i.e. contains mistyped policy
+ // values).
+ // - Returns true if |dict| was valid or got normalized.
+ bool NormalizePolicies(base::DictionaryValue* dict);
+
+ // Stores |new_policies| into |old_policies_|. Returns dictionary with items
+ // from |new_policies| that are different from the old |old_policies_|.
+ scoped_ptr<base::DictionaryValue> StoreNewAndReturnChangedPolicies(
+ scoped_ptr<base::DictionaryValue> new_policies);
+
// Signals policy error to the registered |PolicyErrorCallback|.
void SignalPolicyError();
« no previous file with comments | « remoting/host/it2me/it2me_host.cc ('k') | remoting/host/policy_watcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698