diff options
author | Markus Fischer <mfischer@php.net> | 2002-01-03 14:32:36 +0000 |
---|---|---|
committer | Markus Fischer <mfischer@php.net> | 2002-01-03 14:32:36 +0000 |
commit | 7603d13733be667c3b5d99336281c36e24775300 (patch) | |
tree | d6497b9b31665ddc81ae3ea1ecfe881df3ec01ad /ext/ftp/php_ftp.c | |
parent | 9b391a83c2f06e4e2185ab37d1427b70e48fc94f (diff) | |
download | php-git-7603d13733be667c3b5d99336281c36e24775300.tar.gz |
- Now use ZE's builtin zend_zval_type_name().
Diffstat (limited to 'ext/ftp/php_ftp.c')
-rw-r--r-- | ext/ftp/php_ftp.c | 36 |
1 files changed, 1 insertions, 35 deletions
diff --git a/ext/ftp/php_ftp.c b/ext/ftp/php_ftp.c index 81718e9f39..49ed65ff94 100644 --- a/ext/ftp/php_ftp.c +++ b/ext/ftp/php_ftp.c @@ -708,40 +708,6 @@ PHP_FUNCTION(ftp_close) } /* }}} */ -/* Temporarely copied over from zend_API.c until it gets exposed */ -static char *ze_zval_type_name(zval *arg) -{ - switch (Z_TYPE_P(arg)) { - case IS_NULL: - return "null"; - - case IS_LONG: - return "integer"; - - case IS_DOUBLE: - return "double"; - - case IS_STRING: - return "string"; - - case IS_ARRAY: - return "array"; - - case IS_OBJECT: - return "object"; - - case IS_BOOL: - return "boolean"; - - case IS_RESOURCE: - return "resource"; - - default: - return "unknown"; - } -} - - /* {{{ proto bool ftp_set_option(resource stream, int option, mixed value) Sets an FTP option */ PHP_FUNCTION(ftp_set_option) @@ -760,7 +726,7 @@ PHP_FUNCTION(ftp_set_option) case PHP_FTP_OPT_TIMEOUT_SEC: if (Z_TYPE_P(z_value) != IS_LONG) { php_error(E_WARNING, "%s(): option TIMEOUT_SEC expects value of type long, %s given", - get_active_function_name(TSRMLS_C), ze_zval_type_name(z_value)); + get_active_function_name(TSRMLS_C), zend_zval_type_name(z_value)); RETURN_FALSE; } if (Z_LVAL_P(z_value) <= 0) { |