Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 19 Nov 2024 19:51:56 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 277959] Refactor of usr.sbin/daemon caused regression in restart parameter
Message-ID:  <bug-277959-227-4UlBY7jWZT@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-277959-227@https.bugs.freebsd.org/bugzilla/>

index | next in thread | previous in thread | raw e-mail

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=277959

--- Comment #16 from commit-hook@FreeBSD.org ---
A commit in branch main references this bug:

URL:
https://cgit.FreeBSD.org/src/commit/?id=9ab59e900c1dd693b4d14285389a035e81341789

commit 9ab59e900c1dd693b4d14285389a035e81341789
Author:     Kyle Evans <kevans@FreeBSD.org>
AuthorDate: 2024-11-19 19:51:27 +0000
Commit:     Kyle Evans <kevans@FreeBSD.org>
CommitDate: 2024-11-19 19:51:27 +0000

    daemon: tests: add a test for missed SIGTERM

    This is somewhaht hard to test reliably, but we'll give it a shot.  Startup
    a sleep(1) daemon with a hefty restart delay.  In refactoring of daemon(8),
    we inadvertently started dropping SIGTERMs that came in while we were
    waiting to restart the child, so we employ the strategy:

     - Pop the child sleep(1) first
     - Wait for sleep(1) to exit (pid file truncated)
     - Pop the daemon(8) with a SIGTERM
     - Wait for daemon(8) to exit

    The pidfile is specifically truncated outside of the event loop so that we
    don't have a kqueue to catch it in the current model.

    PR:             277959
    Reviewed by:    des, markj
    Differential Revision:  https://reviews.freebsd.org/D47005

 usr.sbin/daemon/tests/daemon_test.sh | 38 ++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-277959-227-4UlBY7jWZT>