felipe Sun Jun 29 13:21:03 2008 UTC Modified files: (Branch: PHP_5_3) /php-src/ext/dbase dbase.c Log: - New parameter parsing API http://cvs.php.net/viewvc.cgi/php-src/ext/dbase/dbase.c?r1=1.74.2.2.2.9.2.3&r2=1.74.2.2.2.9.2.4&diff_format=u Index: php-src/ext/dbase/dbase.c diff -u php-src/ext/dbase/dbase.c:1.74.2.2.2.9.2.3 php-src/ext/dbase/dbase.c:1.74.2.2.2.9.2.4 --- php-src/ext/dbase/dbase.c:1.74.2.2.2.9.2.3 Wed Jun 25 14:46:18 2008 +++ php-src/ext/dbase/dbase.c Sun Jun 29 13:21:02 2008 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: dbase.c,v 1.74.2.2.2.9.2.3 2008/06/25 14:46:18 felipe Exp $ */ +/* $Id: dbase.c,v 1.74.2.2.2.9.2.4 2008/06/29 13:21:02 felipe Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -829,20 +829,20 @@ */ PHP_FUNCTION(dbase_get_header_info) { - zval **dbh_id, *row; + zval *row; dbfield_t *dbf, *cur_f; dbhead_t *dbh; int dbh_type; + long dbh_id; DBase_TLS_VARS; - if (ZEND_NUM_ARGS() != 1 || (zend_get_parameters_ex(1, &dbh_id) == FAILURE)) { - WRONG_PARAM_COUNT; + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &dbh_id) == FAILURE) { + return; } - convert_to_long_ex(dbh_id); - dbh = zend_list_find(Z_LVAL_PP(dbh_id), &dbh_type); + dbh = zend_list_find(dbh_id, &dbh_type); if (!dbh || dbh_type != DBase_GLOBAL(le_dbhead)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", Z_LVAL_PP(dbh_id)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find database for identifier %ld", dbh_id); RETURN_FALSE; }
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php