Having both a working and a failing version available, I nailed it down to a difference in behavior of ImageMagick. This is not dependent on the version of Ghostscript (I tried both with 8.15.4 and with the newest 8.63). The working, older version of ImageMagick invokes gs twice, like that:
Code: Select all
gs -q -dBATCH -dSAFER -dMaxBitmap=500000000 -dNOPAUSE -dAlignToPixels=0 -sDEVICE=pnmraw -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -g612x792 -r72x72 -sOutputFile=/tmp/magick-XXEgyteI -f/tmp/magick-XXjKAqoW -f/tmp/magicpnVw4t
gs -q -dBATCH -dSAFER -dMaxBitmap=500000000 -dNOPAUSE -dAlignToPixels=0 -sDEVICE=pnmraw -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -g612x792 -r72x72 -sOutputFile=/tmp/magick-XXEgyteI -f/tmp/magick-XXjKAqoW -f/tmp/magicpnVw4t -c showpage
It seems that it does not happen with all Postscript files. An example input file which does cause trouble can be downloaded from here: https://bi.offis.de/imagemagick_bug/frame_001.ps