php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #58889 GMagickDraw::setFillColor crashes with an invalid object parameter
Submitted: 2009-10-11 15:38 UTC Modified: 2009-10-11 19:10 UTC
From: felipe@php.net Assigned:
Status: Closed Package: gmagick (PECL)
PHP Version: 5_3 CVS-2009-10-11 (dev) OS:
Private report: No CVE-ID: None
 [2009-10-11 15:38 UTC] felipe@php.net
Description:
------------
See below.

Reproduce code:
---------------
Starting program: /usr/local/bin/php -dextension=gmagick.so -r '$x = new gmagickdraw; $x->setfillcolor(new stdclass);'
[Thread debugging using libthread_db enabled]
[New Thread 0xb5ca36b0 (LWP 20405)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xb5ca36b0 (LWP 20405)]
0xb5ad0b80 in PixelGetQuantumColor () from /usr/lib/libGraphicsMagickWand.so.0
(gdb) bt
#0  0xb5ad0b80 in PixelGetQuantumColor () from /usr/lib/libGraphicsMagickWand.so.0
#1  0xb5abeea9 in MagickDrawSetFillColor () from /usr/lib/libGraphicsMagickWand.so.0
#2  0xb5af6f13 in zim_gmagickdraw_setfillcolor (ht=1, return_value=0xa6a8fc4, return_value_ptr=0x0, this_ptr=0xa6a80d0, return_value_used=0, 
    tsrm_ls=0xa540050) at /home/felipe/dev/pecl/gmagick/gmagickdraw_methods.c:550
#3  0x0846721d in zend_do_fcall_common_helper_SPEC (execute_data=0xa6d6e7c, tsrm_ls=0xa540050)
    at /home/felipe/dev/php5/Zend/zend_vm_execute.h:313
#4  0x084683e4 in ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER (execute_data=0xa6d6e7c, tsrm_ls=0xa540050)
    at /home/felipe/dev/php5/Zend/zend_vm_execute.h:418
#5  0x08465f02 in execute (op_array=0xa6a8714, tsrm_ls=0xa540050) at /home/felipe/dev/php5/Zend/zend_vm_execute.h:104
#6  0x08425429 in zend_eval_stringl (str=0xbf882818 "$x = new gmagickdraw; $x->setfillcolor(new stdclass);", str_len=53, retval_ptr=0x0, 
    string_name=0x87d8690 "Command line code", tsrm_ls=0xa540050) at /home/felipe/dev/php5/Zend/zend_execute_API.c:1167
#7  0x084256d8 in zend_eval_stringl_ex (str=0xbf882818 "$x = new gmagickdraw; $x->setfillcolor(new stdclass);", str_len=53, retval_ptr=0x0, 
    string_name=0x87d8690 "Command line code", handle_exceptions=1, tsrm_ls=0xa540050) at /home/felipe/dev/php5/Zend/zend_execute_API.c:1209
#8  0x0842578c in zend_eval_string_ex (str=0xbf882818 "$x = new gmagickdraw; $x->setfillcolor(new stdclass);", retval_ptr=0x0, 
    string_name=0x87d8690 "Command line code", handle_exceptions=1, tsrm_ls=0xa540050) at /home/felipe/dev/php5/Zend/zend_execute_API.c:1220
#9  0x08517b07 in main (argc=4, argv=0xbf881f24) at /home/felipe/dev/php5/sapi/cli/php_cli.c:1229
(gdb) 



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-10-11 19:10 UTC] mkoppanen@php.net
This bug has been fixed in CVS.

In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on pecl.php.net.

In case this was a pecl.php.net website problem, the change will show
up on the website in short time.
 
Thank you for the report, and for helping us make PECL better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 17:01:58 2024 UTC