wait(2) - perldoc - phpman

Markdown | JSON | MCP    


TLDR: wait (tldr-pages)

Wait for a process to complete before proceeding.

  • Wait for a process to finish given its process ID (PID) and return its exit status
    wait {{pid}}
  • Wait for all processes known to the invoking shell to finish
    wait
  • Wait for a job to finish (run `jobs` to find the job number)
    wait %{{job_number}}
  • Display help
    wait --help
    wait    Behaves like wait(2) on your system: it waits for a child
            process to terminate and returns the pid of the deceased
            process, or -1 if there are no child processes. The status is
            returned in $? and "${^CHILD_ERROR_NATIVE}". Note that a return
            value of -1 could mean that child processes are being
            automatically reaped, as described in perlipc.

            If you use "wait" in your handler for $SIG{CHLD}, it may
            accidentally wait for the child created by "qx" or "system". See
            perlipc for details.

            Portability issues: "wait" in perlport.


Generated by phpMan Author: Che Dong Under GNU General Public License
2026-06-02 21:24 @216.73.216.151 CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Valid XHTML 1.0 TransitionalValid CSS!