1--TEST--
2Test for Github issue #59
3--SKIPIF--
4<?php
5    require_once(dirname(__FILE__) . '/skipif.inc');
6
7	if (!extension_loaded ('pcntl'))
8		die("skip");
9?>
10--FILE--
11<?php
12
13include dirname(__FILE__) . '/zeromq_test_helper.inc';
14$server = create_server();
15
16// fork a child to execute cmd, in case it crashes
17$pid = pcntl_fork();
18if ($pid == -1)
19{
20	die('could not fork');
21}
22else if ($pid)
23{
24	// we are the parent
25	pcntl_wait($status);
26	$exitcode = pcntl_wexitstatus($status);
27}
28else
29	exit(0);
30
31echo "OK";
32
33
34--EXPECT--
35OK