summaryrefslogtreecommitdiff
path: root/apps/gui/skin_engine/skin_render.c
diff options
context:
space:
mode:
authorJonathan Gordon <rockbox@jdgordon.info>2010-09-26 06:43:33 +0000
committerJonathan Gordon <rockbox@jdgordon.info>2010-09-26 06:43:33 +0000
commit562437b8e7e2c7f3bd65b3d6e4bd4c196fa77f35 (patch)
tree2945c24ab7c93cdec6d4825db610883d647b20fc /apps/gui/skin_engine/skin_render.c
parent3131fb9712be306789b23507ad8b491cd505f702 (diff)
downloadrockbox-562437b8e7e2c7f3bd65b3d6e4bd4c196fa77f35.tar.gz
rockbox-562437b8e7e2c7f3bd65b3d6e4bd4c196fa77f35.zip
Fix FS#1159 - stack overflow in the skin engine when there is too many nested conditionals
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28167 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/gui/skin_engine/skin_render.c')
-rw-r--r--apps/gui/skin_engine/skin_render.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/apps/gui/skin_engine/skin_render.c b/apps/gui/skin_engine/skin_render.c
index 4fbd550c72..baa1f82b43 100644
--- a/apps/gui/skin_engine/skin_render.c
+++ b/apps/gui/skin_engine/skin_render.c
@@ -382,11 +382,9 @@ static bool skin_render_line(struct skin_element* line, struct skin_draw_info *i
382 struct skin_element *child = line->children[0]; 382 struct skin_element *child = line->children[0];
383 struct conditional *conditional; 383 struct conditional *conditional;
384 skin_render_func func = skin_render_line; 384 skin_render_func func = skin_render_line;
385 char tempbuf[128];
386 int old_refresh_mode = info->refresh_type; 385 int old_refresh_mode = info->refresh_type;
387 while (child) 386 while (child)
388 { 387 {
389 tempbuf[0] = '\0';
390 switch (child->type) 388 switch (child->type)
391 { 389 {
392 case CONDITIONAL: 390 case CONDITIONAL:
@@ -447,6 +445,7 @@ static bool skin_render_line(struct skin_element* line, struct skin_draw_info *i
447 } 445 }
448 if (!do_non_text_tags(info->gwps, info, child, &info->skin_vp->vp)) 446 if (!do_non_text_tags(info->gwps, info, child, &info->skin_vp->vp))
449 { 447 {
448 static char tempbuf[128];
450 const char *value = get_token_value(info->gwps, child->data, 449 const char *value = get_token_value(info->gwps, child->data,
451 info->offset, tempbuf, 450 info->offset, tempbuf,
452 sizeof(tempbuf), NULL); 451 sizeof(tempbuf), NULL);