summaryrefslogtreecommitdiff
path: root/update_manager/policy_test_utils.h
diff options
context:
space:
mode:
authorAmin Hassani <ahassani@chromium.org>2019-08-14 19:41:03 -0700
committerCommit Bot <commit-bot@chromium.org>2019-08-27 19:50:50 +0000
commita2c8b92227ddf33fd934357d0aea39bbe36e6293 (patch)
tree08c55997efd9ffb442f748f0ff72798fa79168be /update_manager/policy_test_utils.h
parentfbb600fa0499c0bfdc9923814c430a6e629f4d6a (diff)
update_engine: Replace scoped_refptr with shared_ptr in update_manager
It seems like scoped_refptr was a substitute for shared_ptr before chromium was on C++11: https://www.chromium.org/developers/smart-pointer-guidelines But that is not the case anymore as we are already on C++14. So just replace it in update_manager with shared_ptr. There is still another use case of it for keeping dbus connections but that can't easily be changed because brillo::DBusConnection is still using scoped_refptr. BUG=chromium:994048 TEST=FEATURES=test emerge update_engine Change-Id: I1fab0408399d678d2851731aea40fc02be459295 Reviewed-on: https://chromium-review.googlesource.com/c/aosp/platform/system/update_engine/+/1755262 Reviewed-by: Jae Hoon Kim <kimjae@chromium.org> Reviewed-by: Sen Jiang <senj@chromium.org> Tested-by: Amin Hassani <ahassani@chromium.org> Commit-Queue: Amin Hassani <ahassani@chromium.org>
Diffstat (limited to 'update_manager/policy_test_utils.h')
-rw-r--r--update_manager/policy_test_utils.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/update_manager/policy_test_utils.h b/update_manager/policy_test_utils.h
index eb5758f0..cd94907d 100644
--- a/update_manager/policy_test_utils.h
+++ b/update_manager/policy_test_utils.h
@@ -93,7 +93,7 @@ class UmPolicyTestBase : public ::testing::Test {
brillo::FakeMessageLoop loop_{nullptr};
chromeos_update_engine::FakeClock fake_clock_;
FakeState fake_state_;
- scoped_refptr<EvaluationContext> eval_ctx_;
+ std::shared_ptr<EvaluationContext> eval_ctx_;
std::unique_ptr<Policy> policy_;
};