mirror of
https://github.com/fail0verflow/switch-coreboot.git
synced 2025-05-04 01:39:18 -04:00
The checksum creation in lar starts somewhere in the lar image,
and ends at the end of a temporary buffer, which doesn't look right to me (and segfaults if between those two there's an unmapped region, as happened here). Signed-off-by: Patrick Georgi <patrick@georgi-clan.de> Acked-by: Stefan Reinauer <stepan@coresystems.de> Acked-by: Uwe Hermann <uwe@hermann-uwe.de> git-svn-id: svn://coreboot.org/repository/LinuxBIOSv3@480 f3766cd6-281f-0410-b1cd-43a5c92072e9
This commit is contained in:
parent
d73c7038ba
commit
eb1a12cf8d
1 changed files with 1 additions and 1 deletions
|
@ -666,7 +666,7 @@ int lar_add_file(struct lar *lar, const char *name)
|
|||
|
||||
csum = 0;
|
||||
for (walk = (u32 *) (lar->map + offset);
|
||||
walk < (u32 *) (temp + complen + hlen);
|
||||
walk < (u32 *) (lar->map + complen + hlen);
|
||||
walk++) {
|
||||
csum += ntohl(*walk);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue