]> git.ipfire.org Git - thirdparty/u-boot.git/commit
ofnode: NULL check bootscr_flash_size before dereference
authorAndrew Goodbody <andrew.goodbody@linaro.org>
Mon, 7 Jul 2025 10:04:29 +0000 (11:04 +0100)
committerTom Rini <trini@konsulko.com>
Mon, 14 Jul 2025 21:16:56 +0000 (15:16 -0600)
commitcd79a2839b01571b6f2915c219f71c05e3c97482
treed8e3695659c7c48f59f45907e66837526b0b8641
parent5f70be08b015a5dc2296ea0073ecc8165fc48588
ofnode: NULL check bootscr_flash_size before dereference

Move the NULL check of bootscr_flash_size to before the first time it is
dereferenced to avoid any possible segment violations.

This issue found by Smatch.

Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
drivers/core/ofnode.c