Fix -Wloop-analysis: rlz/
This has no effect on performance; it makes explicit a lifetime extension of a temp that was already occurring. Bug: 1223264 Change-Id: Idb1ec8d46f3117ec2257ec70453009de23e062db Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3023462 Auto-Submit: Peter Kasting <pkasting@chromium.org> Commit-Queue: Sylvain Defresne <sdefresne@chromium.org> Reviewed-by: Sylvain Defresne <sdefresne@chromium.org> Cr-Commit-Position: refs/heads/master@{#901018}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
57f2b68b60
commit
aa5329f773
@ -163,7 +163,7 @@ absl::optional<base::Value> CopyWithoutEmptyChildren(const base::Value& value) {
|
|||||||
case base::Value::Type::DICTIONARY: {
|
case base::Value::Type::DICTIONARY: {
|
||||||
base::Value::DictStorage storage;
|
base::Value::DictStorage storage;
|
||||||
|
|
||||||
for (const auto& key_value_pair : value.DictItems()) {
|
for (const auto key_value_pair : value.DictItems()) {
|
||||||
absl::optional<base::Value> item_copy =
|
absl::optional<base::Value> item_copy =
|
||||||
CopyWithoutEmptyChildren(key_value_pair.second);
|
CopyWithoutEmptyChildren(key_value_pair.second);
|
||||||
if (item_copy)
|
if (item_copy)
|
||||||
|
Reference in New Issue
Block a user