[Magick-bugs] malformed tif crashes perl on win32

Justin DeVuyst justin at devuyst.com
Wed Jan 10 13:57:29 CST 2007


Hello,

I have a tif file that seems to be malformed (I can send it to anyone
who wants it).  I say this because when I try to run the code below on
linux I get this:

Exception 350: 2000x2000.tif: unknown field with tag 34665 (0x8769)
encountered.

That's cool.  But when I run the same code with that tif on win32,
perl crashes hard.  I get some system error like "perl.exe has
generated errors and willl be closed by windows.  You will need to
restart the program."  The fatal error seems to be related to the png
Write() call because writing to tif or jpg doesn't produce any error
(which is fairly odd in itself as well).

OS: Win2K SP4
Perl: ActiveState build 817 (5.8.8)
ImageMagick: 6.2.7-8 Q16

Thanks,
       JDV

<snip>
#!perl

use strict;
use warnings;
use Image::Magick;

my $infile  = '2000x2000.tif';
my $outfile = '2000x2000_out.png';

my $img = Image::Magick->new;

my $read_return = $img->Read( $infile );
$read_return and die "Unable to read $infile: $read_return";

my $ret = $img->Write( filename => $outfile );
$ret and die "Unable to write $outfile: $ret";
</snip>







More information about the Magick-bugs mailing list