mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
Merge branch 'PHP-8.2' into PHP-8.3
This commit is contained in:
commit
0306983fa4
3 changed files with 0 additions and 39 deletions
2
NEWS
2
NEWS
|
@ -36,8 +36,6 @@ PHP NEWS
|
||||||
- PGSQL:
|
- PGSQL:
|
||||||
. Fixed bug GH-13354 (pg_execute/pg_send_query_params/pg_send_execute
|
. Fixed bug GH-13354 (pg_execute/pg_send_query_params/pg_send_execute
|
||||||
with null value passed by reference). (George Barbarosie)
|
with null value passed by reference). (George Barbarosie)
|
||||||
. Fixed bug GH-13519 (PGSQL_CONNECT_FORCE_RENEW not working with persistent
|
|
||||||
connections. (David Carlier)
|
|
||||||
|
|
||||||
- SPL:
|
- SPL:
|
||||||
. Fixed bug GH-13531 (Unable to resize SplfixedArray after being unserialized
|
. Fixed bug GH-13531 (Unable to resize SplfixedArray after being unserialized
|
||||||
|
|
|
@ -566,7 +566,6 @@ static void php_pgsql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent)
|
||||||
|
|
||||||
/* try to find if we already have this link in our persistent list */
|
/* try to find if we already have this link in our persistent list */
|
||||||
if ((le = zend_hash_find_ptr(&EG(persistent_list), str.s)) == NULL) { /* we don't */
|
if ((le = zend_hash_find_ptr(&EG(persistent_list), str.s)) == NULL) { /* we don't */
|
||||||
newpconn:
|
|
||||||
if (PGG(max_links) != -1 && PGG(num_links) >= PGG(max_links)) {
|
if (PGG(max_links) != -1 && PGG(num_links) >= PGG(max_links)) {
|
||||||
php_error_docref(NULL, E_WARNING,
|
php_error_docref(NULL, E_WARNING,
|
||||||
"Cannot create new link. Too many open links (" ZEND_LONG_FMT ")", PGG(num_links));
|
"Cannot create new link. Too many open links (" ZEND_LONG_FMT ")", PGG(num_links));
|
||||||
|
@ -595,12 +594,6 @@ newpconn:
|
||||||
PGG(num_links)++;
|
PGG(num_links)++;
|
||||||
PGG(num_persistent)++;
|
PGG(num_persistent)++;
|
||||||
} else { /* we do */
|
} else { /* we do */
|
||||||
if ((connect_type & PGSQL_CONNECT_FORCE_NEW)) {
|
|
||||||
if (zend_hash_del(&EG(persistent_list), str.s) != SUCCESS) {
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
goto newpconn;
|
|
||||||
}
|
|
||||||
if (le->type != le_plink) {
|
if (le->type != le_plink) {
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,30 +0,0 @@
|
||||||
--TEST--
|
|
||||||
GH-13519 - PGSQL_CONNECT_FORCE_NEW with persistent connections.
|
|
||||||
--EXTENSIONS--
|
|
||||||
pgsql
|
|
||||||
--SKIPIF--
|
|
||||||
<?php include("skipif.inc"); ?>
|
|
||||||
--FILE--
|
|
||||||
<?php
|
|
||||||
include 'config.inc';
|
|
||||||
|
|
||||||
$db1 = pg_pconnect($conn_str);
|
|
||||||
$pid1 = pg_get_pid($db1);
|
|
||||||
for ($i = 0; $i < 3; $i ++) {
|
|
||||||
$db2 = pg_pconnect($conn_str);
|
|
||||||
var_dump($pid1 === pg_get_pid($db2));
|
|
||||||
}
|
|
||||||
for ($i = 0; $i < 3; $i ++) {
|
|
||||||
$db2 = pg_pconnect($conn_str, PGSQL_CONNECT_FORCE_NEW);
|
|
||||||
var_dump($pid1 === pg_get_pid($db2));
|
|
||||||
pg_close($db2);
|
|
||||||
}
|
|
||||||
pg_close($db1);
|
|
||||||
?>
|
|
||||||
--EXPECT--
|
|
||||||
bool(true)
|
|
||||||
bool(true)
|
|
||||||
bool(true)
|
|
||||||
bool(false)
|
|
||||||
bool(false)
|
|
||||||
bool(false)
|
|
Loading…
Add table
Add a link
Reference in a new issue