Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: support COMPACT/OFFSET16 packed resources. #3372

Merged
merged 5 commits into from
Oct 6, 2023
Merged

Conversation

iBotPeaches
Copy link
Owner

@iBotPeaches iBotPeaches commented Oct 5, 2023

fixes #3367 && fixes #3366


  • read entry data - support flag/size difference
  • set res values - split regular/compact/complex
  • set entry data - dig into specNamesId for compact set
  • read entry - prevent assuming specNamesId for compact resources
  • offset16 parsing - properly calculate offsets for offset16 resources
  • tests - add sample with both offset16 and compact resources

Sample can be found here for tool authors who stumble on this - https://github.com/iBotPeaches/TestApks/tree/master/Issue3366

@iBotPeaches
Copy link
Owner Author

You need more than 1 string entry to trigger the inclusion of some of these optimizations. So this packs my test application to 1000+ strings (and only strings) and it appears to be a valid OFFSET16/COMPACT app.

iBotPeaches/TestApks@b3d866d

@iBotPeaches iBotPeaches marked this pull request as ready for review October 6, 2023 10:51
@iBotPeaches iBotPeaches changed the title fix: support COMPACT/OFFSET16 fix: support COMPACT/OFFSET16 packed resources. Oct 6, 2023
@iBotPeaches iBotPeaches added this to the v2.9.0 milestone Oct 6, 2023
@iBotPeaches iBotPeaches merged commit 959b6de into master Oct 6, 2023
31 checks passed
@iBotPeaches iBotPeaches deleted the issue-3366 branch October 6, 2023 11:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Android 14 - support for 16-bit entry offsets Android 14 - compact resource entries
1 participant