Page 1 of 1

this is bug ?

Posted: 2008-08-04T17:35:53-07:00
by onesoft
Core occurred during the execution
This issue is raised from the function below it.
(image.c)
MagickExport ImageInfo *AcquireImageInfo(void)
{
ImageInfo
*image_info;

image_info=(ImageInfo *) AcquireMagickMemory(sizeof(*image_info));
if (image_info == (ImageInfo *) NULL)
ThrowFatalException(ResourceLimitFatalError,"MemoryAllocationFailed");
GetImageInfo(image_info);
return(image_info);

}

Under the above functions are being modified as disagree?
Memory allocation fails, it still function despite calls by GetImageInfo
Core occurs
==>
MagickExport ImageInfo *AcquireImageInfo(void)
{
ImageInfo
*image_info;

image_info=(ImageInfo *) AcquireMagickMemory(sizeof(*image_info));
if (image_info == (ImageInfo *) NULL){
ThrowFatalException(ResourceLimitFatalError,"MemoryAllocationFailed");
return(image_info);
};
GetImageInfo(image_info);
return(image_info);

}

Re: this is bug ?

Posted: 2008-08-04T17:52:16-07:00
by magick
ThrowFatalException() calls _exit(1) and the program should exit. You suggest it does not. Can you post a method to reliably reproduce the problem?

Re: this is bug ?

Posted: 2008-08-04T21:31:49-07:00
by onesoft
I did not even look at the function, did not see the mistakes ThrowFatalException handeut.

Sources from the core occurs on a particular image

Image *image;
ImageInfo *image_info;
image_info=CloneImageInfo((ImageInfo *) NULL); <- Core points raised
(void)strcpy(image_info->filename, src_path);
image=ReadImage(image_info, &exception); <- Core points raised

So source of concern mentioned above were found to function,
If the error until the end of the function ThrowFatalException once again he will not look like
The image is a TIFF format image information, we want to use it for more than libtiff without action.
But the program has occurred in coded on the Unix core,
Loading the image in the viewer window in the following warning message appears
unknown field with tag 292(0x124) encountered. 'TIFFReadDirectory'
TIFF image as a JPEG image resize operations due to difficulties of trying to form a variety of images
There are many. Recommendations worth asking if the solution is.

Re: this is bug ?

Posted: 2008-08-05T10:36:24-07:00
by magick
We have not seen this exception before. Are you using a modern version of ImageMagick, the latest is 6.4.2-6? Do you have more than version of ImageMagick installed? What OS are you using? Did you build from source? If so, type
  • make check
and see if the validation tests pass.