Commit 0ac3ad8c authored by Marc Treib's avatar Marc Treib Committed by Commit Bot

Refactor about_sync_util.cc to remove unsafe usage of raw pointers

The previous [Bool|Int|String]SyncStat classes relied on raw pointers
into base::ListValue, which is bad because they become invalid when
the actual std::vector backing the list gets resized. They're replaced
by new SectionList/Section/Stat classes that are less fragile.
While we're here, this also updates the code to use the new base::Value
APIs, i.e. using values instead of unique_ptrs.

Bug: 702230
Change-Id: I5da50857587acb50ffb8849a7fa2cf8dabce9e45
Reviewed-on: https://chromium-review.googlesource.com/955324
Commit-Queue: Marc Treib <treib@chromium.org>
Reviewed-by: default avatarMikel Astiz <mastiz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#543384}
parent f72e9811
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment