summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator_test.cpp
diff options
context:
space:
mode:
authorJames O'Leary <jamesoleary@google.com>2021-03-02 19:52:26 -0500
committerJames O'Leary <jamesoleary@google.com>2021-03-03 10:46:16 -0500
commitbbfe962fff3d654b1fa19c0876e86c6dc4d16df2 (patch)
tree675e000b4928021fe9b864f69623310fe527774c /tools/aapt2/java/JavaClassGenerator_test.cpp
parentf98091f2e1fc0f0ee2794f6bc5b226647cfafebd (diff)
Fix crash when number of pixels < max colors
If extraction is run on a set of pixels whose count is less than the number of max colors, then colors.length < max colors, and accesses to colors[index] inside the for loop throw an ArrayOutOfBoundsException. Test: add widget to home screen, reduce size of widget to small area. observe crash. `mp core services` with fix, observe that crash no longer occurs. `mp core services` again without fix, verify crash occurs after boot. Fixes: 181130209 Change-Id: I60bf1ab39f7a69f2fb0745049fd46d2f0b53a12c
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions