Assertion failed using -label with PDF
Swiss army knife of image processing
Brought to you by:
bfriesen
Using GraphicsMagick 1.4 snapshot-20210228 Q16 from the Debian graphicsmagick package version 1.4+really1.3.36+hg16481-1 or GraphicsMagick 1.4 snapshot-20210718 Q8 built from current tip (59c8ee0db7b9), if the -label option is given when writing a PDF, the following assertion failure occurs:
$ gm convert -label MyLabel xc:#ffffff labeled.pdf gm: magick/memory.c:678: _MagickReallocateResourceLimitedMemory: Assertion `memory_resource.signature == MagickSignature' failed. gm convert: abort due to signal 6 (SIGABRT) "Abort"...
I would have expected that either -label would set a PDF metadata tag or be silently ignored as it appears to be for other formats which do not support -label.
Thanks,
Kevin
On Tue, 20 Jul 2021, Kevin Locke wrote:
This issue is likely a simple source-code bug of using the wrong
reallocator/dealloctor. It is not due to a command-line error.
Thanks for making me aware of this.
Bob
Bob Friesenhahn
bfriesen@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
Public Key, http://www.simplesystems.org/users/bfriesen/public-key.txt
This problem is fixed by Mercurial changeset 16545:22aaff86b4aa. Thank you very much for this report.
If you have not done so already I strongly recommend opening a report in the Debian bug tracker so that they can update the Debian package with the fix.
Thank you very much for the fast analysis and fix!
Good idea. I had not reported it to Debian yet, but have now done so in Bug 991380.