From: fortunate-lee Date: Wed, 19 Nov 2025 01:59:18 +0000 (+0800) Subject: kill: the situation where fd is opened but not closed X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c62bb65ad321eebea18f32f5529f8f0a085e57e2;p=thirdparty%2Futil-linux.git kill: the situation where fd is opened but not closed Signed-off-by: fortunate-lee --- diff --git a/misc-utils/kill.c b/misc-utils/kill.c index df83548f6..245c3b6b7 100644 --- a/misc-utils/kill.c +++ b/misc-utils/kill.c @@ -557,6 +557,9 @@ static int kill_with_timeout(const struct kill_control *ctl) err(EXIT_FAILURE, _("pidfd_send_signal() failed")); } } + + close(pfd); + return 0; } #endif