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

Unified Diff: components/policy/core/common/cloud/component_cloud_policy_store.h

Issue 1902633006: Convert //components/policy from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments and use namespace alias Created 4 years, 8 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/cloud/component_cloud_policy_store.h
diff --git a/components/policy/core/common/cloud/component_cloud_policy_store.h b/components/policy/core/common/cloud/component_cloud_policy_store.h
index 345e9abd21b869501f1d12e7bcf75b23ed9a9a5f..f2f4dc1008449e719354b482548a90502e3b0253 100644
--- a/components/policy/core/common/cloud/component_cloud_policy_store.h
+++ b/components/policy/core/common/cloud/component_cloud_policy_store.h
@@ -6,10 +6,10 @@
#define COMPONENTS_POLICY_CORE_COMMON_CLOUD_COMPONENT_CLOUD_POLICY_STORE_H_
#include <map>
+#include <memory>
#include <string>
#include "base/macros.h"
-#include "base/memory/scoped_ptr.h"
#include "base/threading/non_thread_safe.h"
#include "components/policy/core/common/cloud/resource_cache.h"
#include "components/policy/core/common/policy_bundle.h"
@@ -104,7 +104,7 @@ class POLICY_EXPORT ComponentCloudPolicyStore : public base::NonThreadSafe {
// the data referenced there can be downloaded. A |proto| must be validated
// before attempting to download the data, and before storing both.
bool ValidatePolicy(
- scoped_ptr<enterprise_management::PolicyFetchResponse> proto,
+ std::unique_ptr<enterprise_management::PolicyFetchResponse> proto,
PolicyNamespace* ns,
enterprise_management::ExternalPolicyData* payload);
@@ -112,7 +112,7 @@ class POLICY_EXPORT ComponentCloudPolicyStore : public base::NonThreadSafe {
// Helper for ValidatePolicy(), that's also used to validate protobufs
// loaded from the disk cache.
bool ValidateProto(
- scoped_ptr<enterprise_management::PolicyFetchResponse> proto,
+ std::unique_ptr<enterprise_management::PolicyFetchResponse> proto,
const std::string& policy_type,
const std::string& settings_entity_id,
enterprise_management::ExternalPolicyData* payload,

Powered by Google App Engine
This is Rietveld 408576698