git: e56687bb2d32 - main - ctld: Return from the inner "main" loop on EINTR
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 20 Apr 2026 17:20:24 UTC
The branch main has been updated by jhb:
URL: https://cgit.FreeBSD.org/src/commit/?id=e56687bb2d32ee4b1774300f3960427ca56b34bb
commit e56687bb2d32ee4b1774300f3960427ca56b34bb
Author: Nikolay Denev <ndenev@gmail.com>
AuthorDate: 2026-04-20 17:18:50 +0000
Commit: John Baldwin <jhb@FreeBSD.org>
CommitDate: 2026-04-20 17:18:50 +0000
ctld: Return from the inner "main" loop on EINTR
This ensures that child processes are reaped in the outer loop in
main().
PR: 294035
Reviewed by: asomers
Fixes: 66b107e82b2f ("ctld: Use kevent(2) for socket events rather than select(2)")
Sponsored by: Chelsio Communications
Differential Revision: https://reviews.freebsd.org/D56525
---
usr.sbin/ctld/ctld.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/usr.sbin/ctld/ctld.cc b/usr.sbin/ctld/ctld.cc
index 331c029e282e..a6c80a3604c3 100644
--- a/usr.sbin/ctld/ctld.cc
+++ b/usr.sbin/ctld/ctld.cc
@@ -2418,7 +2418,7 @@ main_loop(bool dont_fork)
error = kevent(kqfd, NULL, 0, &kev, 1, NULL);
if (error == -1) {
if (errno == EINTR)
- continue;
+ return;
log_err(1, "kevent");
}