Skip Menu |

This queue is for tickets about the Image-Info CPAN distribution.

Report information
The Basics
Id: 29088
Status: resolved
Worked: 10 min
Priority: 0/
Queue: Image-Info

People
Owner: TELS [...] cpan.org
Requestors: msergeant [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 1.25
Fixed in: (no value)



Subject: Another hanging image
Hi Tels, I have another image that causes an infinite loop in extracting exif data. It loops forever doing: SUBIFD InteroperabilityOffset 8 948 SUBIFD ExifOffset 162 948 SUBIFD InteroperabilityOffset 8 948 SUBIFD ExifOffset 162 948 etc (that's with the print debug uncommented on line 983-ish of TIFF.pm) I have a fix that involves doing: return if $self->{seen_field_offset}{$offset}++; in add_fields. Is that a valid fix to never look at the same offset twice?
Subject: Re: [rt.cpan.org #29088] Another hanging image
Date: Fri, 31 Aug 2007 21:17:21 +0200
To: bug-Image-Info [...] rt.cpan.org
From: Tels <nospam-abuse [...] bloodgate.com>
Moin, On Friday 31 August 2007 20:06:41 via RT wrote: Show quoted text
> Fri Aug 31 14:06:34 2007: Request 29088 was acted upon. > Transaction: Ticket created by MSERGEANT > Queue: Image-Info > Subject: Another hanging image > Broken in: 1.25 > Severity: Critical > Owner: Nobody > Requestors: MSERGEANT@cpan.org > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=29088 > > > > Hi Tels, > > I have another image that causes an infinite loop in extracting exif > data. It loops forever doing: > > SUBIFD InteroperabilityOffset 8 948 > SUBIFD ExifOffset 162 948 > SUBIFD InteroperabilityOffset 8 948 > SUBIFD ExifOffset 162 948 > etc > > (that's with the print debug uncommented on line 983-ish of TIFF.pm) > > I have a fix that involves doing: > > return if $self->{seen_field_offset}{$offset}++; > > in add_fields. Is that a valid fix to never look at the same offset > twice?
I have no idea :) But it sounds sensible, if you sent in a patch and a small testimage, I gladly apply it and release another version. thank you for you report! tels -- Signed on Fri Aug 31 21:16:18 2007 with key 0x93B84C15. View my photo gallery: http://bloodgate.com/photos PGP key on http://bloodgate.com/tels.asc or per email. "Den wahren Wert dieser Software werden vermutlich nur Fach Läute und Firmen erkennen." -- "So isst es. Ein gewißer Standart muss schon gewart beiben!" -- Kabe (http://tinyurl.com/3kucx)
Download (untitled)
application/pgp-signature 481b

Message body not shown because it is not plain text.

Here's the patch: --- /usr/lib/perl5/site_perl/5.8.0/Image/TIFF.pm 2007-08-31 21:11:42.000000000 +0100 +++ /usr/lib/perl5/site_perl/5.8.0/Image/TIFF.pm.old 2007-08-31 21:12:37.000000000 +0100 @@ -873,7 +873,6 @@ { my($self, $offset, $ifds, $tags, $voff_plus) = @_; return unless $offset; + return if $self->{seen_offset}{$offset}++; $tags ||= \%tiff_tags; for (${$self->{source}}) { # alias as $_ And I've attached the image.
Download bad_image.jpg
image/jpeg 42.7k
bad_image.jpg
Ugh, sorry about the formatting. Hopefully because it's just one line you can apply it manually.
On Fri Aug 31 16:16:59 2007, MSERGEANT wrote: Show quoted text
> Here's the patch:
I have confirmed that the patch fixes this issue, but I do not want to add this image to the distribution, because there are four people on it - I would need permission of all of them and this is just too messy :) Nevertheless, I release v1.26 soon. All the best, Tels
I have released v1.26 which should fix this issue. If you have further issues, please re-open this bug by replying, or open another bug report. Thank you for your report! :)
Marking as resolved.