summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJosh Law <objecting@objecting.org>2026-03-19 08:43:06 +0900
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2026-03-25 11:06:10 +0100
commit2cf5eff223fc9b720690c16ab763a00788e85c4b (patch)
treef0abcb6be86d43c3f66ce300303318e93bb3c547 /include
parentc1bfc25d62d83160799bd731bcce5d6ab8dfd2a0 (diff)
tools/bootconfig: fix fd leak in load_xbc_file() on fstat failure
[ Upstream commit 3b2c2ab4ceb82af484310c3087541eab00ea288b ] If fstat() fails after open() succeeds, the function returns without closing the file descriptor. Also preserve errno across close(), since close() may overwrite it before the error is returned. Link: https://lore.kernel.org/all/20260318155847.78065-3-objecting@objecting.org/ Fixes: 950313ebf79c ("tools: bootconfig: Add bootconfig command") Signed-off-by: Josh Law <objecting@objecting.org> Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions