New Defects reported by Coverity Scan for coreboot
scan-admin--- via coreboot <[email protected]>
| Newsgroups | gmane.linux.bios |
|---|---|
| Message-ID | <[email protected]> |
Hi,
Please find the latest report on new defect(s) introduced to coreboot found with Coverity Scan.
1 new defect(s) introduced to coreboot found with Coverity Scan.
New defect(s) Reported-by: Coverity Scan
Showing 1 of 1 defect(s)
** CID 1540835: Null pointer dereferences (REVERSE_INULL)
/util/amdfwtool/amdfwtool.c: 533 in fill_dir_header()
________________________________________________________________________________________________________
*** CID 1540835: Null pointer dereferences (REVERSE_INULL)
/util/amdfwtool/amdfwtool.c: 533 in fill_dir_header()
527 psp_directory_table *dir = directory;
528 bios_directory_table *bdir = directory;
529 /* The cookies have same offsets. */
530 uint32_t cookie = ((psp_directory_table *)directory)->header.cookie;
531 uint32_t table_size = 0;
532
>>> CID 1540835: Null pointer dereferences (REVERSE_INULL)
>>> Null-checking "directory" suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
533 if (ctx == NULL || directory == NULL) {
534 fprintf(stderr, "Calling %s with NULL pointers\n", __func__);
535 return;
536 }
537
538 /* The table size needs to be 0x1000 aligned. So align the end of table. */
________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=u001.AxU2LYlgjL6eX23u9ErQy-2BKADyCpvUKOL6EWmZljiu5RTlgzSxHNU8YEiZyg63VT4oV0wHomK1tUxgwyYstzK0M2Ed2Cv7gFreqR3FCBLpU-3Dr6yZ_3AAg4m2Qo6X8uGGmBm-2BJP2cELf0dkUfIv8-2BPwY7td4pvJzoag9qct-2BfQIAC4xb8PDXIBFEgcYQJFk6DPiHBAPy-2FXFMNQyi0Ie6kHJC6Go78Mll0BItzrA5YieJ6IYWl5NLJgdNW1ka0VBaMI0m9IJbcwcK7DIrIBw2-2BLhijfalSTzJ4TIvaWMPUJxUrlazqBTHv4N9eyOKcI4n8Qt0H-2Blg-3D-3D
_______________________________________________
coreboot mailing list -- [email protected]
To unsubscribe send an email to [email protected]