Fix ZPP of pg_lo_export()

Closes GH-11132
This commit is contained in:
Máté Kocsis 2023-04-25 23:20:39 +02:00
parent 3a76f795f8
commit f0149c5c0b
No known key found for this signature in database
GPG Key ID: FD055E41728BF310
2 changed files with 4 additions and 1 deletions

3
NEWS
View File

@ -5,6 +5,9 @@ PHP NEWS
- Opcache:
. Fixed bug GH-11134 (Incorrect match default branch optimization). (ilutov)
- PGSQL:
. Fixed parameter parsing of pg_lo_export(). (kocsismate)
11 May 2023, PHP 8.1.19
- Core:

View File

@ -2760,7 +2760,7 @@ PHP_FUNCTION(pg_lo_export)
/* allow string to handle large OID value correctly */
if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS(),
"rlP", &pgsql_link, pgsql_link_ce, &oid_long, &file_out) == SUCCESS) {
"OlP", &pgsql_link, pgsql_link_ce, &oid_long, &file_out) == SUCCESS) {
if (oid_long <= (zend_long)InvalidOid) {
zend_value_error("Invalid OID value passed");
RETURN_THROWS();