fix mustRun() in sigchild environments

When being run in sigchild environments, the sigchild compatibility
mode needs to be enabled to be able to call `getExitCode()`. Since
`mustRun()` uses `getExitCode()` to determine whether or not a process
terminated successfully, it cannot be used in sigchild environments
when the sigchild compatibility mode is disabled.
bug #11791 [Process] fix mustRun() in sigchild environments (xabbuh)

This PR was merged into the 2.5 branch.

Discussion
----------

[Process] fix mustRun() in sigchild environments

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

When being run in sigchild environments, the sigchild compatibility mode needs to be enabled to be able to call `getExitCode()`. Since `mustRun()` uses `getExitCode()` to determine whether or not a process terminated successfully, it cannot be used in sigchild environments when the sigchild compatibility mode is disabled.

Commits
-------

b764f6c fix mustRun() in sigchild environments