diff options
-rw-r--r-- | sapi/cli/tests/sapi_windows_set_ctrl_handler.phpt | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sapi/cli/tests/sapi_windows_set_ctrl_handler.phpt b/sapi/cli/tests/sapi_windows_set_ctrl_handler.phpt index dbb02a00bd..09030c90f8 100644 --- a/sapi/cli/tests/sapi_windows_set_ctrl_handler.phpt +++ b/sapi/cli/tests/sapi_windows_set_ctrl_handler.phpt @@ -56,11 +56,13 @@ if ($is_child) { $status = proc_get_status($proc); if ($status["running"]) { echo "Child $child_pid didn't exit after ${max}us\n"; + foreach ($pipes as $pipe) { + fclose($pipe); + } + proc_terminate($proc); } else { echo "Child $child_pid exit with status ", $status["exitcode"], " after ${total}us\n"; } - - proc_close($proc); } function get_evt_name(int $evt) : ?string |