|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #59126 readimageblob results in a segmentation fault
Submitted: 2010-03-21 02:13 UTC Modified: 2010-03-21 04:23 UTC
From: swernst at gmail dot com Assigned:
Status: Closed Package: gmagick (PECL)
PHP Version: 5.3.1 OS: linux (fedora 12 x64)
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
16 + 16 = ?
Subscribe to this entry?

 [2010-03-21 02:13 UTC] swernst at gmail dot com
When using the readimageblob method to convert a binary string into a valid image resource, the readimageblob method results in a segmentation fault if the second file name argument is not supplied.

Reproduce code:
Given a valid image file stored as a binary string in the variable $data, execution fails on :

$img = Gmagick();

However, execution succeeds on:

$img = Gmagick();
$img->readimageblob($data, 'dummyfilename');

where the only difference is to include a value for the second file name argument.

Expected result:
I expected the binary string stored in $data to be processed by the method as a valid Gmagick image resource for further processing.

Actual result:
Following notice written to apache error logs:

exit signal Segmentation fault (11)


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2010-03-21 02:17 UTC] swernst at gmail dot com
Oh, more precisely the reproduce code should properly read:

This one fails:

$img = new Gmagick();

and this one succeeds:

$img = new Gmagick();
$img->readimageblob($data, 'dummyfilename');
 [2010-03-21 04:23 UTC]
This bug has been fixed in SVN.

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

In case this was a 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-2020 The PHP Group
All rights reserved.
Last updated: Thu Oct 22 10:01:24 2020 UTC