mirror of
https://github.com/php/php-src.git
synced 2025-08-18 06:58:55 +02:00
Add warning to pg_unescape_bytea() when invalid parameter is passed
This commit is contained in:
parent
d1c261d7f8
commit
2bc8271b29
1 changed files with 1 additions and 0 deletions
|
@ -4212,6 +4212,7 @@ PHP_FUNCTION(pg_unescape_bytea)
|
||||||
to = (char *)php_pgsql_unescape_bytea((unsigned char*)from, &to_len);
|
to = (char *)php_pgsql_unescape_bytea((unsigned char*)from, &to_len);
|
||||||
#endif
|
#endif
|
||||||
if (!to) {
|
if (!to) {
|
||||||
|
php_error_docref(NULL TSRMLS_CC, E_WARNING,"Failed to unescape");
|
||||||
RETURN_FALSE;
|
RETURN_FALSE;
|
||||||
}
|
}
|
||||||
RETVAL_STRINGL(to, to_len, 0);
|
RETVAL_STRINGL(to, to_len, 0);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue