I have an issue that's either caused by me being dumb (a strong possibility) or an issue in the latest IM (6.7.5-6). I have a small image conversion program that I wrote to help with some day-to-day tasks and I was previously using IM version 6.4.7 in which this code worked. Wanting to keep up with the times, I upgraded to 6.7.5-6 and I now get an error. The code (I did remove some error checking code, etc to keep it as simple as possible but I will add it back if requested) is:
Code: Select all
MagickRemoveImageProfile(wand,"ICC",&length);
exception = AcquireExceptionInfo();
if (strcmp(currentColorspace, "cmyk") == 0) {
cmykProfile = FileToBlob("USWebCoatedSWOP.icc",~0UL,&length,exception);
MagickSetImageProfile(wand,"ICC",cmykProfile,length);
}
rgbProfile = FileToBlob("sRGB.icc",~0UL,&length,exception);
MagickProfileImage(wand,"ICC",rgbProfile,length);
MagickSetImageColorspace(wand, RGBColorspace);
MagickWriteImages(wand,file->tempfile,MagickTrue);
wand = DestroyMagickWand(wand);
MagickWandTerminus();
magick/semaphore.c:273: LockSemaphoreInfo: Assertion `semaphore_info != (SemaphoreInfo *) ((void *)0)' failed.
Like I said, this worked great before so I either I had a bug that worked in my favour or something has changed and I need to adapt my code. Any thoughts/comments/etc are appreciated!
Thanks,
David