pajoye                                   Mon, 03 Jan 2011 15:35:01 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=307029

Log:
- fix crash when argc > 1 and to_zval is NULL (thx tony for the headup)

Changed paths:
    U   php/php-src/trunk/ext/gd/gd_ctx.c

Modified: php/php-src/trunk/ext/gd/gd_ctx.c
===================================================================
--- php/php-src/trunk/ext/gd/gd_ctx.c   2011-01-03 14:39:48 UTC (rev 307028)
+++ php/php-src/trunk/ext/gd/gd_ctx.c   2011-01-03 15:35:01 UTC (rev 307029)
@@ -118,7 +118,7 @@
                }
        }

-       if (argc > 1) {
+       if (argc > 1 && to_zval) {
                if (Z_TYPE_P(to_zval) == IS_RESOURCE) {
                        php_stream_from_zval_no_verify(stream, &to_zval);
                        if (stream == NULL) {

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to