Seg fault while using Magick api read blob for a SVG image

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
RelaxedMaverick
Posts: 4
Joined: 2014-05-13T12:22:34-07:00
Authentication code: 6789

Seg fault while using Magick api read blob for a SVG image

Post by RelaxedMaverick »

Hi
Am using ImageMagick-6.7.3-9 and hit a problem while using void read ( const Blob &blob_ );
The same SVG image works via the other api - void read ( const std::string &imageSpec_ );
My library is wrapped via JNI and hence i pass the image buffer to Magick. Have verified that the blob is intact and there are no data issues, and the same code works fine for jpg/png etc.

Have also verified that i don't have delegate problem.

Code: Select all

$ identify -list format | grep SVG
     MSVG  SVG       rw+   ImageMagick's own SVG internal renderer
      SVG  SVG       rw+   Scalable Vector Graphics (RSVG 2.26.0)
     SVGZ  SVG       rw+   Compressed Scalable Vector Graphics (RSVG 2.26.0)

$ identify astrotheme-z7622ARXqDKt.svg
astrotheme-z7622ARXqDKt.svg SVG 380x300 380x300+0+0 16-bit DirectClass 15.9kb 
Here is the Segfault
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007f4388e1fe70, pid=14086, tid=139928360810240
#
# JRE version: Java(TM) SE Runtime Environment (7.0_51-b13) (build 1.7.0_51-b13)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (24.51-b03 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# C [libpixman-1.so.0+0x4fe70] _pixman_lookup_composite_function+0x50
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /home/rohitd/PixProcessorDeps/packages/hs_err_pid14086.log
#
# If you would like to submit a bug report, please visit:
# http://bugreport.sun.com/bugreport/crash.jsp
#
Aborted
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: Seg fault while using Magick api read blob for a SVG ima

Post by dlemstra »

Can you upgrade to the latest version of ImageMagick and reproduce the same problem?
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
RelaxedMaverick
Posts: 4
Joined: 2014-05-13T12:22:34-07:00
Authentication code: 6789

Re: Seg fault while using Magick api read blob for a SVG ima

Post by RelaxedMaverick »

Thanks dlemstra
I can try the upgrade path, but its going to take sometime as we have other modules dependent on IM as well.
Just wanted to check in the forum if this is a known issue or others have seen this before as well.
RelaxedMaverick
Posts: 4
Joined: 2014-05-13T12:22:34-07:00
Authentication code: 6789

Re: Seg fault while using Magick api read blob for a SVG ima

Post by RelaxedMaverick »

dlemstra wrote:Can you upgrade to the latest version of ImageMagick and reproduce the same problem?
The Pro tip worked :)
Updated to latest version (ImageMagick-6.8.9-6) and the problem vanishes.
Post Reply