Remove useless error check for bin2hex()

And change prototype accordingly...

Closes GH-4550.
This commit is contained in:
George Peter Banyard 2019-08-16 22:44:21 +02:00 committed by Nikita Popov
parent b78347ba35
commit 2505edb40d

View File

@ -223,7 +223,7 @@ PHP_MSHUTDOWN_FUNCTION(localeconv)
/* }}} */
#endif
/* {{{ proto string|false bin2hex(string data)
/* {{{ proto string bin2hex(string data)
Converts the binary representation of data to hex */
PHP_FUNCTION(bin2hex)
{
@ -236,10 +236,6 @@ PHP_FUNCTION(bin2hex)
result = php_bin2hex((unsigned char *)ZSTR_VAL(data), ZSTR_LEN(data));
if (!result) {
RETURN_FALSE;
}
RETURN_STR(result);
}
/* }}} */