]> granicus.if.org Git - php/commitdiff
password_hash() can't return false
authorNikita Popov <nikita.ppv@gmail.com>
Fri, 15 Nov 2019 11:43:22 +0000 (12:43 +0100)
committerNikita Popov <nikita.ppv@gmail.com>
Fri, 15 Nov 2019 11:43:57 +0000 (12:43 +0100)
ext/standard/basic_functions.stub.php
ext/standard/basic_functions_arginfo.h

index 8c878b74e9d334acb848fd7fddb782980d2d2fda..b35b84fffa40a4c7072e0f2d49282a847df15c50 100755 (executable)
@@ -991,7 +991,7 @@ function unpack(string $format, string $data, int $offset = 0): array|false {}
 
 function password_get_info(string $hash): ?array {}
 
-function password_hash(string $password, $algo, array $options = []): string|false|null {}
+function password_hash(string $password, $algo, array $options = []): ?string {}
 
 function password_needs_rehash(string $hash, $algo, array $options = []): bool {}
 
index 431830d6324be2c03fd1b6659dee467b2d8cbf01..f62df22daea54a0518d576d79fa572775aa2bb30 100755 (executable)
@@ -1476,7 +1476,7 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_password_get_info, 0, 1, IS_ARRA
        ZEND_ARG_TYPE_INFO(0, hash, IS_STRING, 0)
 ZEND_END_ARG_INFO()
 
-ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_password_hash, 0, 2, MAY_BE_STRING|MAY_BE_FALSE|MAY_BE_NULL)
+ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_password_hash, 0, 2, IS_STRING, 1)
        ZEND_ARG_TYPE_INFO(0, password, IS_STRING, 0)
        ZEND_ARG_INFO(0, algo)
        ZEND_ARG_TYPE_INFO(0, options, IS_ARRAY, 0)