mirror of
https://github.com/php/php-src.git
synced 2025-08-16 14:08:47 +02:00
Formalize pdo_dbh_check_liveness_func() return type to zend_result
This commit is contained in:
parent
ca5fcb83bf
commit
6728c1bd72
4 changed files with 4 additions and 4 deletions
|
@ -265,7 +265,7 @@ typedef int (*pdo_dbh_get_attr_func)(pdo_dbh_t *dbh, zend_long attr, zval *val);
|
||||||
/* checking/pinging persistent connections; return SUCCESS if the connection
|
/* checking/pinging persistent connections; return SUCCESS if the connection
|
||||||
* is still alive and ready to be used, FAILURE otherwise.
|
* is still alive and ready to be used, FAILURE otherwise.
|
||||||
* You may set this handler to NULL, which is equivalent to returning SUCCESS. */
|
* You may set this handler to NULL, which is equivalent to returning SUCCESS. */
|
||||||
typedef int (*pdo_dbh_check_liveness_func)(pdo_dbh_t *dbh);
|
typedef zend_result (*pdo_dbh_check_liveness_func)(pdo_dbh_t *dbh);
|
||||||
|
|
||||||
/* called at request end for each persistent dbh; this gives the driver
|
/* called at request end for each persistent dbh; this gives the driver
|
||||||
* the opportunity to safely release resources that only have per-request
|
* the opportunity to safely release resources that only have per-request
|
||||||
|
|
|
@ -520,7 +520,7 @@ static int pdo_mysql_get_attribute(pdo_dbh_t *dbh, zend_long attr, zval *return_
|
||||||
/* }}} */
|
/* }}} */
|
||||||
|
|
||||||
/* {{{ pdo_mysql_check_liveness */
|
/* {{{ pdo_mysql_check_liveness */
|
||||||
static int pdo_mysql_check_liveness(pdo_dbh_t *dbh)
|
static zend_result pdo_mysql_check_liveness(pdo_dbh_t *dbh)
|
||||||
{
|
{
|
||||||
pdo_mysql_db_handle *H = (pdo_mysql_db_handle *)dbh->driver_data;
|
pdo_mysql_db_handle *H = (pdo_mysql_db_handle *)dbh->driver_data;
|
||||||
|
|
||||||
|
|
|
@ -651,7 +651,7 @@ static int oci_handle_get_attribute(pdo_dbh_t *dbh, zend_long attr, zval *return
|
||||||
}
|
}
|
||||||
/* }}} */
|
/* }}} */
|
||||||
|
|
||||||
static int pdo_oci_check_liveness(pdo_dbh_t *dbh) /* {{{ */
|
static zend_result pdo_oci_check_liveness(pdo_dbh_t *dbh) /* {{{ */
|
||||||
{
|
{
|
||||||
pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data;
|
pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data;
|
||||||
sb4 error_code = 0;
|
sb4 error_code = 0;
|
||||||
|
|
|
@ -488,7 +488,7 @@ static int pdo_pgsql_get_attribute(pdo_dbh_t *dbh, zend_long attr, zval *return_
|
||||||
}
|
}
|
||||||
|
|
||||||
/* {{{ */
|
/* {{{ */
|
||||||
static int pdo_pgsql_check_liveness(pdo_dbh_t *dbh)
|
static zend_result pdo_pgsql_check_liveness(pdo_dbh_t *dbh)
|
||||||
{
|
{
|
||||||
pdo_pgsql_db_handle *H = (pdo_pgsql_db_handle *)dbh->driver_data;
|
pdo_pgsql_db_handle *H = (pdo_pgsql_db_handle *)dbh->driver_data;
|
||||||
if (!PQconsumeInput(H->server) || PQstatus(H->server) == CONNECTION_BAD) {
|
if (!PQconsumeInput(H->server) || PQstatus(H->server) == CONNECTION_BAD) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue