Skip to content
Commit b636250e authored by David Oberhollenzer's avatar David Oberhollenzer
Browse files

mtd-utils: Fix potential negative arguments passed to close(2)



Many tools open a file descriptor, close it a the end and have some
form of error path in between that jumps to the end.

In some cases, if opening the file fails the error path is taken and
the utility ends up closing one or more invalid file descriptors. It's
technically not a real issue but something that pretty much any static
analysis tool barks at.

Signed-off-by: default avatarDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>
parent 11bc41c3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment