[Bug 268580] Add shutdown delay to daemon(8)

From: <bugzilla-noreply_at_freebsd.org>
Date: Fri, 14 Apr 2023 20:08:43 UTC

--- Comment #3 from Ihor Antonov <ihor@antonovs.family> ---
Nathan's motivation for  the shutdown delay is to avoid race conditions caused
by asynchronous signal processing. 

After https://reviews.freebsd.org/rG8935a3993219be76c7ea03e9ad4509657d08af6c
was merged none of the described situations are possible.

1. Upon receiving SIGTERM daemon will propagate it to the child, then wait for
child to exit and then read everything until EOF from the pipe.

2. Same with the pid file: Child's pidfile cleanup happens only after child
reported SIGCHILD, all the data was read from the pipe.

At this point I do not see a compelling usecase for shutdown delay feature.

You are receiving this mail because:
You are the assignee for the bug.