xref: /PHP-8.2/ext/pcntl/tests/bug47566.phpt (revision 74859783)
1--TEST--
2Bug #47566 (return value of pcntl_wexitstatus())
3--EXTENSIONS--
4pcntl
5--FILE--
6<?php
7$pid = pcntl_fork();
8if ($pid == -1) {
9 echo "Unable to fork";
10 exit;
11} elseif ($pid) {
12 $epid = pcntl_waitpid(-1,$status);
13 var_dump(pcntl_wexitstatus($status));
14} else {
15 exit(128);
16}
17?>
18--EXPECT--
19int(128)
20