MFC r314886,r314943,r314944: r314886: pwait: Add a -t flag to specify a timeout before exiting, and tests. r314943: Remove unneeded -x from tests. r314944: Rename some tests to end in _test.
Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle.Prune svn:mergeinfo from the new branch, as nothing has been mergedhere.Additional commits post-branch will follow.Approved by: re (implicit)Sponsored by: The FreeBSD Foundation
Use a different way to silence clang analyzer as done in r245494 byexplicitly telling the compiler that we are on the exit route.X-MFC: together with r245494
Free memory before exiting in order to silence a warning from the clangstatic analyzerApproved by: cpercivaMFC after: 3 days
Add pwait utility, which waits for any process to terminate.This is similar to the Solaris utility of the same name.Some use cases:* rc.subr's wait_for_pids* interactive use, e.g. to shut down the computer when some task is done even if the task is already runningDiscussed on: hackers@