diff options
author | Solomon Peachy <pizza@shaftnet.org> | 2020-05-04 14:38:47 -0400 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2020-05-04 20:41:12 +0200 |
commit | b450707955677917fd2687d5d5d6700ce9d59930 (patch) | |
tree | 18911fe345249d90834e3e2daac8b4525dabeaf4 /lib/skin_parser/skin_debug.c | |
parent | 83d8b25fdabb1ddce50e6424c27b97394b74d5ac (diff) | |
download | rockbox-b450707955677917fd2687d5d5d6700ce9d59930.tar.gz rockbox-b450707955677917fd2687d5d5d6700ce9d59930.zip |
skins: Fix buffer overflow in skin_error_format_message()
Change-Id: I54849866c163f2ec7ab9c9f76cfe1b267a4bee56
Diffstat (limited to 'lib/skin_parser/skin_debug.c')
-rw-r--r-- | lib/skin_parser/skin_debug.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/skin_parser/skin_debug.c b/lib/skin_parser/skin_debug.c index 43cd746253..ff26819bc0 100644 --- a/lib/skin_parser/skin_debug.c +++ b/lib/skin_parser/skin_debug.c | |||
@@ -322,7 +322,7 @@ void skin_error_format_message(void) | |||
322 | text[i++] = '.'; | 322 | text[i++] = '.'; |
323 | text[i++] = '.'; | 323 | text[i++] = '.'; |
324 | text[i++] = '.'; | 324 | text[i++] = '.'; |
325 | for (j=error_col-10; error_line_start[j] && error_line_start[j] != '\n'; j++) | 325 | for (j=error_col-10; j < len && error_line_start[j] && error_line_start[j] != '\n'; j++) |
326 | text[i++] = error_line_start[j]; | 326 | text[i++] = error_line_start[j]; |
327 | text[i] = '\0'; | 327 | text[i] = '\0'; |
328 | error_col = 18; | 328 | error_col = 18; |