imagefilter() currently throws double "wrong param count" error.
Attached is a patch for HEAD that fixes it.
-Hannes
Index: ext/gd/gd.c
===================================================================
RCS file: /repository/php-src/ext/gd/gd.c,v
retrieving revision 1.358
diff -u -r1.358 gd.c
--- ext/gd/gd.c 7 Oct 2006 18:12:04 -0000 1.358
+++ ext/gd/gd.c 8 Oct 2006 14:11:47 -0000
@@ -4509,8 +4509,10 @@
php_image_filter_smooth
};
- if (ZEND_NUM_ARGS() < 2 || ZEND_NUM_ARGS() > 5 ||
zend_parse_parameters(2 TSRMLS_CC, "rl", &tmp, &filtertype) == FAILURE) {
- ZEND_WRONG_PARAM_COUNT();
+ if (ZEND_NUM_ARGS() < 2 || ZEND_NUM_ARGS() > 5) {
+ WRONG_PARAM_COUNT;
+ } else if (zend_parse_parameters(2 TSRMLS_CC, "rl", &tmp, &filtertype)
== FAILURE) {
+ return;
}
if (filtertype >= 0 && filtertype <= IMAGE_FILTER_MAX) {
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php