Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 59d5a5a9 authored by Mårten Kongstad's avatar Mårten Kongstad Committed by Todd Kennedy
Browse files

idmap: use more robust data structures

The problem of creating idmap data consists of three steps:

  1. create the mapping overlay resid -> target resid
  2. fix the padding between the target resids
  3. write the mapping as a binary stream

Because we iterate over the resources in the overlay package, there are
no guarantees on the order in which target resources are processed. This
means we can't fix the padding until after step 1. On the other hand,
after step 2 the mapping should be immutable.

Introduce new data structures that help enforce immutability and
ownership of data, as outlined above.

Bug: 80150169
Test: make libandroidfw_tests
Test: atest OverlayHostTests OverlayDeviceTests
Change-Id: I45689e8003c96d251a63a758f77609972ae963df
parent 19b3c371
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment