HomeFreeBSD

rc.subr: Fix wait_for_pids

Description

rc.subr: Fix wait_for_pids

It looks like this function was intended to loop and print an update
whenever at least one of the waited-for processes terminates. However,
the default behavior of pwait is to block until none of the watched
processes exist. Use pwait -o instead so it only blocks until at least
one process terminates, and add a test.

Sponsored by: Klara, Inc.
Sponsored by: NetApp, Inc.
Reviewed by: siderop1_netapp.com, kevans
Differential Revision: https://reviews.freebsd.org/D51691

(cherry picked from commit 7f04c09fe74535c1646a4af120f8f1342fe1c328)

Details

Provenance
desAuthored on Aug 1 2025, 11:11 PM
Reviewer
siderop1_netapp.com
Differential Revision
D51691: rc.subr: Fix wait_for_pids
Parents
rG08a2145902a7: mktemp.1: Document TMPDIR in ENVIRONMENT
Branches
Unknown
Tags
Unknown