Re: bug GtkCurve::get_vector???
| From: | Andrei Zmievski | Date: | Mon, 23 Oct 2006 15:52:38 +0000 |
| Subject: | Re: bug GtkCurve::get_vector??? | ||
| References: | 1 | Groups: | php.gtk.dev |
| Request: | Send a blank email to php-gtk-dev+get-3490@lists.php.net to get a copy of this message | ||
The declaration of "gfloat vector[num]" is illegal under compilers that don't adhere to C99 standard. You have to allocate it via emalloc instead.
-Andrei
On Oct 23, 2006, at 8:24 AM, xxoes wrote:
there are 2 bugs. 1. gfloat vector[num]; musst be defined at beginning of the function 2. num is not a constant //line 1973 "ext\gtk+/gtk.overrides" static PHP_METHOD(GtkCurve, get_vector) { int num, i;NOT_STATIC_METHOD();if (!php_gtk_parse_args(ZEND_NUM_ARGS(), "i", &num))return;gfloat vector[num]; gtk_curve_get_vector(GTK_CURVE(PHPG_GOBJECT(this_ptr)), num, vector);array_init(return_value);for (i = 0; i < num; i++) {add_next_index_double(return_value, vector[i]);} } mfg xxoes -- PHP-GTK Development Mailing List (http://gtk.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php