diff options
author | Aidan MacDonald <amachronic@protonmail.com> | 2022-04-24 12:43:34 +0100 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2024-04-21 20:38:25 -0400 |
commit | 6cbcde13b9eb10b50724f956ba5696fc82ed7cf4 (patch) | |
tree | bf1745be9527256c58fcf2baeda8c2c7aaec3f37 /apps | |
parent | 591a83a0892b6acc2b81ccdbcfb48b5391090e7c (diff) | |
download | rockbox-6cbcde13b9eb10b50724f956ba5696fc82ed7cf4.tar.gz rockbox-6cbcde13b9eb10b50724f956ba5696fc82ed7cf4.zip |
skin engine: Fix bug with touch region labeling
Auto-created regions associated with a progress bar did not have
a label which could result in an out of bounds read when looking
up touch regions by label. Fix by initializing the label to NULL.
Change-Id: Ic12d697a6a5a45dad977f307471b91db9e607bd5
Diffstat (limited to 'apps')
-rw-r--r-- | apps/gui/skin_engine/skin_parser.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/apps/gui/skin_engine/skin_parser.c b/apps/gui/skin_engine/skin_parser.c index ac68b0dcba..be25bd0125 100644 --- a/apps/gui/skin_engine/skin_parser.c +++ b/apps/gui/skin_engine/skin_parser.c | |||
@@ -1287,6 +1287,7 @@ static int parse_progressbar_tag(struct skin_element* element, | |||
1287 | region->last_press = -1; | 1287 | region->last_press = -1; |
1288 | region->armed = false; | 1288 | region->armed = false; |
1289 | region->bar = PTRTOSKINOFFSET(skin_buffer, pb); | 1289 | region->bar = PTRTOSKINOFFSET(skin_buffer, pb); |
1290 | region->label = PTRTOSKINOFFSET(skin_buffer, NULL); | ||
1290 | 1291 | ||
1291 | item = new_skin_token_list_item(NULL, region); | 1292 | item = new_skin_token_list_item(NULL, region); |
1292 | if (!item) | 1293 | if (!item) |