1
0
Fork 0
forked from len0rd/rockbox

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
This commit is contained in:
Aidan MacDonald 2022-04-24 12:43:34 +01:00 committed by Solomon Peachy
parent 591a83a089
commit 6cbcde13b9

View file

@ -1287,6 +1287,7 @@ static int parse_progressbar_tag(struct skin_element* element,
region->last_press = -1;
region->armed = false;
region->bar = PTRTOSKINOFFSET(skin_buffer, pb);
region->label = PTRTOSKINOFFSET(skin_buffer, NULL);
item = new_skin_token_list_item(NULL, region);
if (!item)