diff options
| author | 2024-08-21 16:49:15 +0000 | |
|---|---|---|
| committer | 2024-08-22 19:44:54 +0000 | |
| commit | c10a4c7fa41e823c0ddaac8e91c3497c4540e301 (patch) | |
| tree | d20b2855d221724dbbba9cb79e43853ca7984226 /libs/androidfw/StringPool.cpp | |
| parent | aba7df49bb9e389607027a36df398eb0ab1bd265 (diff) | |
Fix getHistoricalProcessStartReasons ordering
Ordering is currently done with launch timestamp, however, this is
set to monotonic time since boot which can cause an ordering issue
with persisted records after a reboot.
To fix this, introduce a private created timestamp set to
monotonic time that persists across reboots, thereby ensuring that
records remain ordered by time they were added across reboots and
time changes.
Test: Start device, let run for a bit, trigger a record, wait for
persist, reboot, trigger another record, check and confirm
ordering is correct by making sure they're ordered greatest to
lowest by created time and that timestamp 0 is not ordered.
Test: run new tests
Bug: 360299551
Flag: EXEMPT - bugfix
Change-Id: I45cbae99c6e6848498ba0c668bead099042948ce
Diffstat (limited to 'libs/androidfw/StringPool.cpp')
0 files changed, 0 insertions, 0 deletions