#!/usr/bin/perl use Image::Magick; use strict; use warnings; my $image = Image::Magick->new; open(IMAGE, \*DATA); my $err = $image->Read(file=>\*IMAGE); close(IMAGE); if ($err) { print "Error b: $err\n"; exit(1); } print qq(OK\n); exit(0) __DATA__