mirror of
https://github.com/php/php-src.git
synced 2026-04-23 07:58:20 +02:00
Boolify pdo_stmt_describe_columns()
This commit is contained in:
+1
-1
@@ -1084,7 +1084,7 @@ PHP_METHOD(PDO, query)
|
||||
/* now execute the statement */
|
||||
PDO_STMT_CLEAR_ERR();
|
||||
if (stmt->methods->executer(stmt)) {
|
||||
int ret = 1;
|
||||
bool ret = true;
|
||||
if (!stmt->executed) {
|
||||
if (stmt->dbh->alloc_own_columns) {
|
||||
ret = pdo_stmt_describe_columns(stmt);
|
||||
|
||||
+3
-3
@@ -125,7 +125,7 @@ iterate:
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
int pdo_stmt_describe_columns(pdo_stmt_t *stmt) /* {{{ */
|
||||
bool pdo_stmt_describe_columns(pdo_stmt_t *stmt) /* {{{ */
|
||||
{
|
||||
int col;
|
||||
|
||||
@@ -133,7 +133,7 @@ int pdo_stmt_describe_columns(pdo_stmt_t *stmt) /* {{{ */
|
||||
|
||||
for (col = 0; col < stmt->column_count; col++) {
|
||||
if (!stmt->methods->describer(stmt, col)) {
|
||||
return 0;
|
||||
return false;
|
||||
}
|
||||
|
||||
/* if we are applying case conversions on column names, do so now */
|
||||
@@ -168,7 +168,7 @@ int pdo_stmt_describe_columns(pdo_stmt_t *stmt) /* {{{ */
|
||||
}
|
||||
|
||||
}
|
||||
return 1;
|
||||
return true;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ extern zend_class_entry *pdo_dbstmt_ce;
|
||||
void pdo_dbstmt_free_storage(zend_object *std);
|
||||
zend_object_iterator *pdo_stmt_iter_get(zend_class_entry *ce, zval *object, int by_ref);
|
||||
extern zend_object_handlers pdo_dbstmt_object_handlers;
|
||||
int pdo_stmt_describe_columns(pdo_stmt_t *stmt);
|
||||
bool pdo_stmt_describe_columns(pdo_stmt_t *stmt);
|
||||
bool pdo_stmt_setup_fetch_mode(pdo_stmt_t *stmt, zend_long mode, uint32_t mode_arg_num,
|
||||
zval *args, uint32_t variadic_num_args);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user