mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Accept bool in snmp_set_(quick|enum)_print()
The integer parameter here is actually a boolean. snmp_set_quick_print() already documented it as such, and snmp_get_quick_print() was already returning a boolean.
This commit is contained in:
parent
1fba220725
commit
5480e6b13d
3 changed files with 9 additions and 9 deletions
|
@ -1321,9 +1321,9 @@ PHP_FUNCTION(snmp_get_quick_print)
|
|||
/* {{{ Return all objects including their respective object id within the specified one */
|
||||
PHP_FUNCTION(snmp_set_quick_print)
|
||||
{
|
||||
zend_long a1;
|
||||
zend_bool a1;
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS(), "l", &a1) == FAILURE) {
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS(), "b", &a1) == FAILURE) {
|
||||
RETURN_THROWS();
|
||||
}
|
||||
|
||||
|
@ -1335,9 +1335,9 @@ PHP_FUNCTION(snmp_set_quick_print)
|
|||
/* {{{ Return all values that are enums with their enum value instead of the raw integer */
|
||||
PHP_FUNCTION(snmp_set_enum_print)
|
||||
{
|
||||
zend_long a1;
|
||||
zend_bool a1;
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS(), "l", &a1) == FAILURE) {
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS(), "b", &a1) == FAILURE) {
|
||||
RETURN_THROWS();
|
||||
}
|
||||
|
||||
|
|
|
@ -17,9 +17,9 @@ function snmpset(string $host, string $community, array|string $object_id, array
|
|||
|
||||
function snmp_get_quick_print(): bool {}
|
||||
|
||||
function snmp_set_quick_print(int $quick_print): bool {}
|
||||
function snmp_set_quick_print(bool $quick_print): bool {}
|
||||
|
||||
function snmp_set_enum_print(int $enum_print): bool {}
|
||||
function snmp_set_enum_print(bool $enum_print): bool {}
|
||||
|
||||
function snmp_set_oid_output_format(int $oid_format): bool {}
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/* This is a generated file, edit the .stub.php file instead.
|
||||
* Stub hash: 31a125dde8e52e7849c8cd62ac410be9249a80df */
|
||||
* Stub hash: 4b1adaf7afe143328f1b05c7039fb3d974b29545 */
|
||||
|
||||
ZEND_BEGIN_ARG_WITH_RETURN_OBJ_TYPE_MASK_EX(arginfo_snmpget, 0, 3, stdClass, MAY_BE_ARRAY|MAY_BE_STRING|MAY_BE_BOOL)
|
||||
ZEND_ARG_TYPE_INFO(0, host, IS_STRING, 0)
|
||||
|
@ -37,11 +37,11 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_snmp_get_quick_print, 0, 0, _IS_
|
|||
ZEND_END_ARG_INFO()
|
||||
|
||||
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_snmp_set_quick_print, 0, 1, _IS_BOOL, 0)
|
||||
ZEND_ARG_TYPE_INFO(0, quick_print, IS_LONG, 0)
|
||||
ZEND_ARG_TYPE_INFO(0, quick_print, _IS_BOOL, 0)
|
||||
ZEND_END_ARG_INFO()
|
||||
|
||||
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_snmp_set_enum_print, 0, 1, _IS_BOOL, 0)
|
||||
ZEND_ARG_TYPE_INFO(0, enum_print, IS_LONG, 0)
|
||||
ZEND_ARG_TYPE_INFO(0, enum_print, _IS_BOOL, 0)
|
||||
ZEND_END_ARG_INFO()
|
||||
|
||||
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_snmp_set_oid_output_format, 0, 1, _IS_BOOL, 0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue