Index: ipc/ipc_message_utils.cc |
diff --git a/ipc/ipc_message_utils.cc b/ipc/ipc_message_utils.cc |
index f31add1da14805c95f4ece9a445da88304fbab1f..3bdf20733c7e5d23c3f468912906eb2943306b75 100644 |
--- a/ipc/ipc_message_utils.cc |
+++ b/ipc/ipc_message_utils.cc |
@@ -126,9 +126,8 @@ void GetValueSize(base::PickleSizer* sizer, |
case base::Value::TYPE_LIST: { |
sizer->AddInt(); |
const base::ListValue* list = static_cast<const base::ListValue*>(value); |
- for (base::ListValue::const_iterator it = list->begin(); |
- it != list->end(); ++it) { |
- GetValueSize(sizer, *it, recursion + 1); |
+ for (const auto& entry : *list) { |
+ GetValueSize(sizer, entry.get(), recursion + 1); |
} |
break; |
} |
@@ -199,9 +198,8 @@ void WriteValue(base::Pickle* m, const base::Value* value, int recursion) { |
case base::Value::TYPE_LIST: { |
const base::ListValue* list = static_cast<const base::ListValue*>(value); |
WriteParam(m, static_cast<int>(list->GetSize())); |
- for (base::ListValue::const_iterator it = list->begin(); |
- it != list->end(); ++it) { |
- WriteValue(m, *it, recursion + 1); |
+ for (const auto& entry : *list) { |
+ WriteValue(m, entry.get(), recursion + 1); |
} |
break; |
} |