diff options
Diffstat (limited to 'ext/sqlite/sqlite.c')
-rw-r--r-- | ext/sqlite/sqlite.c | 52 |
1 files changed, 26 insertions, 26 deletions
diff --git a/ext/sqlite/sqlite.c b/ext/sqlite/sqlite.c index 4cf7d95377..85933b10fa 100644 --- a/ext/sqlite/sqlite.c +++ b/ext/sqlite/sqlite.c @@ -2426,8 +2426,8 @@ PHP_FUNCTION(sqlite_column) Returns the version of the linked SQLite library. */ PHP_FUNCTION(sqlite_libversion) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT; + if (zend_parse_parameters_none() == FAILURE) { + return; } RETURN_STRING((char*)sqlite_libversion(), 1); } @@ -2437,8 +2437,8 @@ PHP_FUNCTION(sqlite_libversion) Returns the encoding (iso8859 or UTF-8) of the linked SQLite library. */ PHP_FUNCTION(sqlite_libencoding) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT; + if (zend_parse_parameters_none() == FAILURE) { + return; } RETURN_STRING((char*)sqlite_libencoding(), 1); } @@ -2453,8 +2453,8 @@ PHP_FUNCTION(sqlite_changes) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } DB_FROM_OBJECT(db, object); } else { @@ -2477,8 +2477,8 @@ PHP_FUNCTION(sqlite_last_insert_rowid) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } DB_FROM_OBJECT(db, object); } else { @@ -2514,8 +2514,8 @@ PHP_FUNCTION(sqlite_num_rows) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } RES_FROM_OBJECT(res, object); } else { @@ -2543,8 +2543,8 @@ PHP_FUNCTION(sqlite_valid) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } RES_FROM_OBJECT(res, object); } else { @@ -2567,8 +2567,8 @@ PHP_FUNCTION(sqlite_has_prev) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } RES_FROM_OBJECT(res, object); } else { @@ -2596,8 +2596,8 @@ PHP_FUNCTION(sqlite_num_fields) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } RES_FROM_OBJECT(res, object); } else { @@ -2686,8 +2686,8 @@ PHP_FUNCTION(sqlite_rewind) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } RES_FROM_OBJECT(res, object); } else { @@ -2721,8 +2721,8 @@ PHP_FUNCTION(sqlite_next) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } RES_FROM_OBJECT(res, object); } else { @@ -2756,8 +2756,8 @@ PHP_FUNCTION(sqlite_key) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } RES_FROM_OBJECT(res, object); } else { @@ -2780,8 +2780,8 @@ PHP_FUNCTION(sqlite_prev) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } RES_FROM_OBJECT(res, object); } else { @@ -2849,8 +2849,8 @@ PHP_FUNCTION(sqlite_last_error) zval *object = getThis(); if (object) { - if (ZEND_NUM_ARGS() != 0) { - WRONG_PARAM_COUNT + if (zend_parse_parameters_none() == FAILURE) { + return; } DB_FROM_OBJECT(db, object); } else { |