diff options
author | hscham <hscham@chromium.org> | 2020-07-01 03:48:41 +0000 |
---|---|---|
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | 2020-07-01 03:48:41 +0000 |
commit | e9dbd9968be92190efaa28bcf505e551a3b4fea8 (patch) | |
tree | 942df9a9eeb4fc7f77ce9cc8e8ff81c895144977 | |
parent | 2c55f9e64f4104bd928d82bcba41423912d56d4a (diff) | |
parent | 99900c6a411a50b76dcba71b77e75384b9a5bc05 (diff) | |
download | libbrillo-e9dbd9968be92190efaa28bcf505e551a3b4fea8.tar.gz |
libbrillo: remove base::ValueReferenceAdapter am: 690d8d51a6 am: 7a76d80e7f am: 9620558042 am: 99900c6a41
Original change: https://android-review.googlesource.com/c/platform/external/libbrillo/+/1353563
Change-Id: Ia2dd929e30be1dc6967c21f9e6753e5aac107c1c
-rw-r--r-- | brillo/value_conversion.h | 2 | ||||
-rw-r--r-- | policy/device_policy_impl.cc | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/brillo/value_conversion.h b/brillo/value_conversion.h index 6cf7323..b0d61a1 100644 --- a/brillo/value_conversion.h +++ b/brillo/value_conversion.h @@ -74,7 +74,7 @@ bool FromValue(const base::Value& in_value, std::vector<T, Alloc>* out_value) { return false; out_value->clear(); out_value->reserve(list->GetSize()); - for (const base::Value& item : base::ValueReferenceAdapter(*list)) { + for (const base::Value& item : *list) { T value{}; if (!FromValue(item, &value)) return false; diff --git a/policy/device_policy_impl.cc b/policy/device_policy_impl.cc index 3f96d12..72d30b1 100644 --- a/policy/device_policy_impl.cc +++ b/policy/device_policy_impl.cc @@ -560,7 +560,7 @@ bool DevicePolicyImpl::GetDeviceUpdateStagingSchedule( if (!list_val) return false; - for (const auto& pair_value : base::ValueReferenceAdapter(*list_val)) { + for (const auto& pair_value : *list_val) { const base::DictionaryValue* day_percentage_pair; if (!pair_value.GetAsDictionary(&day_percentage_pair)) return false; @@ -654,7 +654,7 @@ bool DevicePolicyImpl::GetDisallowedTimeIntervals( if (!list_val) return false; - for (const auto& interval_value : base::ValueReferenceAdapter(*list_val)) { + for (const auto& interval_value : *list_val) { const base::DictionaryValue* interval_dict; if (!interval_value.GetAsDictionary(&interval_dict)) { LOG(ERROR) << "Invalid JSON string given. Interval is not a dict."; |