mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
Use new param API in pdo_sqlite
This commit is contained in:
parent
8bbfe174a8
commit
61a43195f5
1 changed files with 17 additions and 12 deletions
|
@ -519,10 +519,12 @@ static PHP_METHOD(SQLite, sqliteCreateFunction)
|
|||
pdo_sqlite_db_handle *H;
|
||||
int ret;
|
||||
|
||||
if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS(), "sz|l",
|
||||
&func_name, &func_name_len, &callback, &argc)) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
ZEND_PARSE_PARAMETERS_START(2, 3)
|
||||
Z_PARAM_STRING(func_name, func_name_len)
|
||||
Z_PARAM_ZVAL_DEREF(callback)
|
||||
Z_PARAM_OPTIONAL
|
||||
Z_PARAM_LONG(argc)
|
||||
ZEND_PARSE_PARAMETERS_END_EX(RETURN_FALSE);
|
||||
|
||||
dbh = Z_PDO_DBH_P(getThis());
|
||||
PDO_CONSTRUCT_CHECK;
|
||||
|
@ -589,10 +591,13 @@ static PHP_METHOD(SQLite, sqliteCreateAggregate)
|
|||
pdo_sqlite_db_handle *H;
|
||||
int ret;
|
||||
|
||||
if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS(), "szz|l",
|
||||
&func_name, &func_name_len, &step_callback, &fini_callback, &argc)) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
ZEND_PARSE_PARAMETERS_START(3, 4)
|
||||
Z_PARAM_STRING(func_name, func_name_len)
|
||||
Z_PARAM_ZVAL_DEREF(step_callback)
|
||||
Z_PARAM_ZVAL_DEREF(fini_callback)
|
||||
Z_PARAM_OPTIONAL
|
||||
Z_PARAM_LONG(argc)
|
||||
ZEND_PARSE_PARAMETERS_END_EX(RETURN_FALSE);
|
||||
|
||||
dbh = Z_PDO_DBH_P(getThis());
|
||||
PDO_CONSTRUCT_CHECK;
|
||||
|
@ -649,10 +654,10 @@ static PHP_METHOD(SQLite, sqliteCreateCollation)
|
|||
pdo_sqlite_db_handle *H;
|
||||
int ret;
|
||||
|
||||
if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS(), "sz",
|
||||
&collation_name, &collation_name_len, &callback)) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
ZEND_PARSE_PARAMETERS_START(2, 2)
|
||||
Z_PARAM_STRING(collation_name, collation_name_len)
|
||||
Z_PARAM_ZVAL_DEREF(callback)
|
||||
ZEND_PARSE_PARAMETERS_END_EX(RETURN_FALSE);
|
||||
|
||||
dbh = Z_PDO_DBH_P(getThis());
|
||||
PDO_CONSTRUCT_CHECK;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue