mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
ext/pcntl: pcnt_setns few nitpicks changes. (#13885)
This commit is contained in:
@@ -1428,7 +1428,7 @@ PHP_FUNCTION(pcntl_setns)
|
||||
switch (errno) {
|
||||
case EINVAL:
|
||||
case ESRCH:
|
||||
zend_argument_value_error(1, "is not a valid process (%d)", pid);
|
||||
zend_argument_value_error(1, "is not a valid process (" ZEND_LONG_FMT ")", pid);
|
||||
RETURN_THROWS();
|
||||
|
||||
case ENFILE:
|
||||
@@ -1455,7 +1455,7 @@ PHP_FUNCTION(pcntl_setns)
|
||||
PCNTL_G(last_error) = errno;
|
||||
switch (errno) {
|
||||
case ESRCH:
|
||||
zend_argument_value_error(1, "process no longer available (%d)", pid);
|
||||
zend_argument_value_error(1, "process no longer available (" ZEND_LONG_FMT ")", pid);
|
||||
RETURN_THROWS();
|
||||
|
||||
case EINVAL:
|
||||
|
||||
@@ -992,5 +992,5 @@ function pcntl_forkx(int $flags): int{}
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_PIDFD_OPEN
|
||||
function pcntl_setns(int $process_id = null, int $nstype = CLONE_NEWNET): bool {}
|
||||
function pcntl_setns(?int $process_id = null, int $nstype = CLONE_NEWNET): bool {}
|
||||
#endif
|
||||
|
||||
4
ext/pcntl/pcntl_arginfo.h
generated
4
ext/pcntl/pcntl_arginfo.h
generated
@@ -1,5 +1,5 @@
|
||||
/* This is a generated file, edit the .stub.php file instead.
|
||||
* Stub hash: 614bd67bb4cfcdc68d37141ff9dfad0a49c318b5 */
|
||||
* Stub hash: e5204cee68c41ff1201992f2572940c8f87980a3 */
|
||||
|
||||
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_pcntl_fork, 0, 0, IS_LONG, 0)
|
||||
ZEND_END_ARG_INFO()
|
||||
@@ -134,7 +134,7 @@ ZEND_END_ARG_INFO()
|
||||
|
||||
#if defined(HAVE_PIDFD_OPEN)
|
||||
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_pcntl_setns, 0, 0, _IS_BOOL, 0)
|
||||
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, process_id, IS_LONG, 0, "null")
|
||||
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, process_id, IS_LONG, 1, "null")
|
||||
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, nstype, IS_LONG, 0, "CLONE_NEWNET")
|
||||
ZEND_END_ARG_INFO()
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user