mirror of https://github.com/thesofproject/sof.git
Merge pull request #28 from marc-hb/copy-sram-overflow
manifest.c: assert buffer overflow in man_copy_sram()
This commit is contained in:
commit
37323face2
|
@ -167,6 +167,8 @@ static int man_copy_sram(struct image *image, Elf32_Shdr *section,
|
|||
void *buffer = image->fw_image + offset;
|
||||
size_t count;
|
||||
|
||||
assert((uint64_t)offset + section->size <= image->adsp->image_size);
|
||||
|
||||
switch (section->type) {
|
||||
case SHT_INIT_ARRAY:
|
||||
/* fall through */
|
||||
|
|
Loading…
Reference in New Issue