fel: sid: fix segfault with default section map
The generic_2k_sid_maps, describing the SID sections for chips where we
don't have any specific information yet, was missing the terminating
NULL section, so we would run off into to woods, beyond the array limit.
This would most commonly result in a segfault:
$ sunxi-fel sid-dump
....
00000000 00000000 00000000 00000000
Segmentation fault (core dumped)
=================
Add the NULL sentinel to terminate the loop correctly.
Signed-off-by: Andre Przywara <osp@andrep.de>
This commit is contained in:
parent
ed3039cdbe
commit
6a2f6b5e32
@ -258,6 +258,7 @@ static const sid_section h6_sid_maps[] = {
|
||||
static const sid_section generic_2k_sid_maps[] = {
|
||||
SID_SECTION("chipid", 0x00, 128),
|
||||
SID_SECTION("unknown", 0x10, 1920),
|
||||
SID_SECTION(NULL, 0, 0),
|
||||
};
|
||||
|
||||
soc_info_t soc_info_table[] = {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user