diff options
author | Matteo Beccati <mbeccati@php.net> | 2009-03-28 01:32:51 +0000 |
---|---|---|
committer | Matteo Beccati <mbeccati@php.net> | 2009-03-28 01:32:51 +0000 |
commit | 724ae4b95e043563952267cd26b36f03470c35bf (patch) | |
tree | 975fecfa3e42620a45ee866f7c8ae767a840b631 /ext/pcntl | |
parent | 155564d727d9f272d2d56ea0260d9b6a80f68599 (diff) | |
download | php-git-724ae4b95e043563952267cd26b36f03470c35bf.tar.gz |
MFH:
- Fixed pcntl_signal() returning NULL when passing wrong parameters
Diffstat (limited to 'ext/pcntl')
-rwxr-xr-x | ext/pcntl/pcntl.c | 2 | ||||
-rw-r--r-- | ext/pcntl/tests/pcntl_signal.phpt | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c index 91fcea3738..8dfcd6cba4 100755 --- a/ext/pcntl/pcntl.c +++ b/ext/pcntl/pcntl.c @@ -757,7 +757,7 @@ PHP_FUNCTION(pcntl_signal) zend_bool restart_syscalls = 1; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lz|b", &signo, &handle, &restart_syscalls) == FAILURE) { - return; + RETURN_FALSE; } if (!PCNTL_G(spares)) { diff --git a/ext/pcntl/tests/pcntl_signal.phpt b/ext/pcntl/tests/pcntl_signal.phpt index 977f26fbcc..324cc0b418 100644 --- a/ext/pcntl/tests/pcntl_signal.phpt +++ b/ext/pcntl/tests/pcntl_signal.phpt @@ -25,7 +25,7 @@ echo "ok\n"; signal dispatched Warning: pcntl_signal() expects at least 2 parameters, 0 given in %s -NULL +bool(false) bool(true) Warning: pcntl_signal(): Invalid value for handle argument specified in %s |