Page 1 of 1

identifyImage() and connection reset

Posted: 2012-03-26T07:17:55-07:00
by davidb2002
Using ImageMagick 6.2.8

I've come across an odd problem with the following code:

Code: Select all

    $image = new Imagick($real_location); 
    $ident = $image->identifyImage(); 
    $format = $ident['colorSpace'];
In most cases, this is fine. But on some photos it resets the connection and basically makes it look like the page has timed out.

An example photo is a JPG at 72dpi, 3008x2000, EXIF data included, RGB, 8Bit-channel.

If i run it like below, its fine:

Code: Select all

    exec("identify -format %r  ".$real_location,$output);
However, i would perfer to stay away from exec() and try to stick to the library if possible.

In my PHP error log i get the following:

Code: Select all

httpd: magick/option.c:1264: GetImageOption: Assertion `image_info != (ImageInfo *) ((void *)0)' failed.
[Mon Mar 26 15:40:26 2012] [notice] child pid 1582 exit signal Aborted (6)