Menu

#646 Assertion failed using -label with PDF

v1.0_(example)
closed-fixed
None
5
2021-07-22
2021-07-20
Kevin Locke
No

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

Discussion

  • Bob Friesenhahn

    Bob Friesenhahn - 2021-07-20

    On Tue, 20 Jul 2021, Kevin Locke wrote:

    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.

    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

     
  • Bob Friesenhahn

    Bob Friesenhahn - 2021-07-22
    • status: open --> closed-fixed
    • assigned_to: Bob Friesenhahn
     
  • Bob Friesenhahn

    Bob Friesenhahn - 2021-07-22

    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.

     
    • Kevin Locke

      Kevin Locke - 2021-07-22

      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.

       

Log in to post a comment.

MongoDB Logo MongoDB