MAGICK_DEBUG gives garbled output and crashes eventually
Posted: 2007-12-06T01:26:11-07:00
I have set MAGICK_DEBUG=Resource
After this the messages of IM appears garbled in the beginning.
The above prints the four letters 'x☺╟ ' in front of all the messages.
In a longer program that invokes many operations this garbling gets longer and longer:
This has been seen using IM 636 Q8 on Linux and Windows.
On Linux the program eventually crashes when MAGICK_DEBUG=Resource is set, with the message:
'*** glibc detected *** malloc(): memory corruption ***
A similar message has not (yet) been seen on Windows.
To me it seems that setting MAGICK_DEBUG=Resource will corrupt memory.
After this the messages of IM appears garbled in the beginning.
Code: Select all
C:\Jacob>convert x.jpg -resample 1000x1000 y.jpg
x☺╟ 6.3.6 Resource convert[4004]: resource.c/AcquireMagickResource/216/Resource
Area: 1.0756mb/1.0756mb/2.98438gb
x☺╟ 6.3.6 Resource convert[4004]: resource.c/AcquireMagickResource/216/Resource
Memory: 1.0756mb/1.0756mb/2.23828gb
x☺╟ 6.3.6 Resource convert[4004]: resource.c/AcquireMagickResource/216/Resource
Area: 207.484mb/207.484mb/2.98438gb
x☺╟ 6.3.6 Resource convert[4004]: resource.c/AcquireMagickResource/216/Resource
Memory: 207.484mb/208.559mb/2.23828gb
x☺╟ 6.3.6 Resource convert[4004]: resource.c/AcquireMagickResource/216/Resource
Area: 14.9388mb/14.9388mb/2.98438gb
x☺╟ 6.3.6 Resource convert[4004]: resource.c/AcquireMagickResource/216/Resource
Memory: 14.9388mb/223.498mb/2.23828gb
In a longer program that invokes many operations this garbling gets longer and longer:
Code: Select all
°¢8D(q►;_§δ↓▌? 6.3.6 Resource ImageMagick[4064]: resource.c/AcquireMagickResource/216/Resource
Area: 174.387mb/174.387mb/2.98438gb 6.3.6 Resource ImageMagick[4064]: resource.c/AcquireMagickResource/216/Resource
Memory: 174.387mb/348.774mb/2.23828gb 6.3.6 Resource ImageMagick[4064]: resource.c/RelinquishMagickResource/824/Resource
Memory: 174.387mb/174.387mb/2.23828gb 74.078u 6.3.6 Resource ImageMagick[4064]: resource.c/AcquireMagickResource/216/Resource
Disk: 174.387mb/174.387mb/4eb ImageMagick[4064]: resource.c/AcquireUniqueFileResource/418/Resource
C:/DOCUME~1/Admin/LOCALS~1/Temp/magick-wFanSi0N ImageMagick[4064]: resource.c/RelinquishUniqueFileResource/857/Resource
C:/DOCUME~1/Admin/LOCALS~1/Temp/magick-wFanSi0N ImageMagick[4064]: resource.c/AcquireUniqueFileResource/418/Resource
C:/DOCUME~1/Admin/LOCALS~1/Temp/magick-fA7t3rBx 1:18 74.094u 6.3.6 Resource ImageMagick[4064]: resource.c/AcquireMagickResource/216/Resource
File: 0b/0b/1.5kb
This has been seen using IM 636 Q8 on Linux and Windows.
On Linux the program eventually crashes when MAGICK_DEBUG=Resource is set, with the message:
'*** glibc detected *** malloc(): memory corruption ***
A similar message has not (yet) been seen on Windows.
To me it seems that setting MAGICK_DEBUG=Resource will corrupt memory.