u-boot/arch/sandbox/cpu
Heinrich Schuchardt 2c3fa4b8ad sandbox: don't call os_close with invalid file descriptor
If open() fails it returns -1. Calling close() with this value
makes no sense. Return -EIO instead.

Addresses-Coverity-ID: 185828 Improper use of negative value
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Fixes: 566bf3a869 ("sandbox: Add a function to read a host file")
Reviewed-by: Sean Anderson <seanga2@gmail.com>
2024-04-17 17:06:16 -06:00
..
cache.c sandbox: Audit config.h and common.h usage 2023-12-21 08:54:37 -05:00
cpu.c Merge patch series "Complete decoupling of bootm logic from commands" 2023-12-21 16:10:00 -05:00
eth-raw-os.c sandbox: missing return value checks in eth-raw-os 2024-04-12 08:53:31 -06:00
Makefile sandbox: fix build failure with musl and SDL 2022-02-09 12:26:12 -07:00
os.c sandbox: don't call os_close with invalid file descriptor 2024-04-17 17:06:16 -06:00
sdl.c sandbox: Audit config.h and common.h usage 2023-12-21 08:54:37 -05:00
spl.c sandbox: Audit config.h and common.h usage 2023-12-21 08:54:37 -05:00
start.c sandbox: Audit config.h and common.h usage 2023-12-21 08:54:37 -05:00
state.c sandbox: Audit config.h and common.h usage 2023-12-21 08:54:37 -05:00
u-boot-spl.lds test: spl: Add functions to create images 2023-10-17 20:50:52 -04:00
u-boot.lds sandbox: eliminate unused functions from binaries 2023-11-02 22:38:01 -04:00