[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#86994: marked as done (findimagedupes: imagemagick code can segfault)

Your message dated Sun, 11 Sep 2005 11:47:06 -0700
with message-id <E1EEWr4-00040x-00@spohr.debian.org>
and subject line Bug#86994: fixed in findimagedupes 0.1.3-6
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

Received: (at submit) by bugs.debian.org; 22 Feb 2001 12:09:54 +0000
>From jhnc%stone@newton.cam.ac.uk Thu Feb 22 06:09:54 2001
Return-path: <jhnc%stone@newton.cam.ac.uk>
Received: from newton.newton.cam.ac.uk [::ffff:] 
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 14VuZG-0002eQ-00; Thu, 22 Feb 2001 06:09:54 -0600
Received: from stone.newton.cam.ac.uk (stone.newton.cam.ac.uk [])
	by newton.newton.cam.ac.uk (8.8.8/8.8.8) with ESMTP id MAA04130
	for <submit@bugs.debian.org>; Thu, 22 Feb 2001 12:09:52 GMT
Received: (from jhnc@localhost)
	by stone.newton.cam.ac.uk (8.11.2/8.11.2/Debian 8.11.2-1) id f1MC9qc05836;
	Thu, 22 Feb 2001 12:09:52 GMT
Date: Thu, 22 Feb 2001 12:09:52 GMT
Message-Id: <200102221209.f1MC9qc05836@stone.newton.cam.ac.uk>
From: Jonathan H N Chin <jhnc%stone@newton.cam.ac.uk>
Subject: findimagedupes: imagemagick code can segfault
To: submit@bugs.debian.org
X-Mailer: bug 3.3.9
Delivered-To: submit@bugs.debian.org

Package: findimagedupes
Version: 0.1.3-1
Severity: important

As the code itself notes, certain file types can cause the imagemagick
routines to crash. One possible way to work around this is:

diff -Bbur old/findimagedupes new/findimagedupes
--- old/findimagedupes	Thu Feb 22 12:07:34 2001
+++ new/findimagedupes	Thu Feb 22 12:05:06 2001
@@ -41,6 +41,8 @@
 my $prog = $0 . '';
 $prog = substr($prog,rindex($prog,'/') + 1) if rindex($prog,'/') >= 0;
+sub handleSEGV { die "caught segfault in getfingerprint()\n"; };
 # check args
 while ($arg = shift) {
@@ -227,7 +229,7 @@
 		print IMGFP "\n";
 	  } elsif (!defined($img)) {
-		warn "warning: unable to get fingerprint of $file.\n";
+		warn "warning: unable to get fingerprint of $file\n";
@@ -246,8 +248,10 @@
     $image = Image::Magick->new;
-    $fp1 = getfingerprint($image, $OPT{'file1'});
-    $fp2 = getfingerprint($image, $OPT{'file2'});
+    $fp1 = getfingerprint($image, $OPT{'file1'})
+	or die "fatal: unable to get fingerprint of $OPT{'file1'}\n";
+    $fp2 = getfingerprint($image, $OPT{'file2'})
+	or die "fatal: unable to get fingerprint of $OPT{'file2'}\n";
     # xor the two binary strings to find differences
     $fpdiff = $fp1 ^ $fp2;
@@ -498,6 +502,8 @@
     my $file = shift;
     my (@blobs, $img);
+    $SIG{SEGV} = \&handleSEGV;
+    my $result = eval {
     $#$image = 0;
@@ -516,10 +522,12 @@
 	# so we'll discard all but the first 32 bytes
 	$img = substr($blobs[0],0,32);
+    };
+    $SIG{SEGV} = 'DEFAULT';
     # free image but don't delete object.
     undef @$image;
-    $img;
+    (defined $result) ? $img: undef;

-- System Information
Debian Release: testing/unstable
Kernel Version: Linux stone 2.2.16int4+usb3 #1 SMP Thu Jul 27 17:18:16 BST 2000 i686 unknown

Versions of the packages findimagedupes depends on:
hi  imagemagick    5.2.9-1        Image manipulation programs.
hi  perl-5.6-base  6              Transitional package.
hi  perlmagick     5.29-4         A perl interface to the libMagick graphics r

Received: (at 86994-close) by bugs.debian.org; 11 Sep 2005 18:50:13 +0000
>From katie@spohr.debian.org Sun Sep 11 11:50:13 2005
Return-path: <katie@spohr.debian.org>
Received: from katie by spohr.debian.org with local (Exim 3.36 1 (Debian))
	id 1EEWr4-00040x-00; Sun, 11 Sep 2005 11:47:06 -0700
From: Andreas Tille <tille@debian.org>
To: 86994-close@bugs.debian.org
X-Katie: $Revision: 1.56 $
Subject: Bug#86994: fixed in findimagedupes 0.1.3-6
Message-Id: <E1EEWr4-00040x-00@spohr.debian.org>
Sender: Archive Administrator <katie@spohr.debian.org>
Date: Sun, 11 Sep 2005 11:47:06 -0700
Delivered-To: 86994-close@bugs.debian.org
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2005_01_02 
	(1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-6.0 required=4.0 tests=BAYES_00,HAS_BUG_NUMBER 
	autolearn=no version=2.60-bugs.debian.org_2005_01_02
X-CrossAssassin-Score: 3

Source: findimagedupes
Source-Version: 0.1.3-6

We believe that the bug you reported is fixed in the latest version of
findimagedupes, which is due to be installed in the Debian FTP archive:

  to pool/main/f/findimagedupes/findimagedupes_0.1.3-6.diff.gz
  to pool/main/f/findimagedupes/findimagedupes_0.1.3-6.dsc
  to pool/main/f/findimagedupes/findimagedupes_0.1.3-6_all.deb

A summary of the changes between this version and the previous one is

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 86994@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
Andreas Tille <tille@debian.org> (supplier of updated findimagedupes package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)

Hash: SHA1

Format: 1.7
Date: Tue, 14 Jun 2005 15:22:51 +0200
Source: findimagedupes
Binary: findimagedupes
Architecture: source all
Version: 0.1.3-6
Distribution: unstable
Urgency: low
Maintainer: Andreas Tille <tille@debian.org>
Changed-By: Andreas Tille <tille@debian.org>
 findimagedupes - Finds visually similar or duplicate images
Closes: 86994 87013 113871 218699
 findimagedupes (0.1.3-6) unstable; urgency=low
   * New maintainer
     Closes: #218699
   * Standards-Version: 3.6.2 (no changes)
   * dh_installmanpages -> dh_installman
   * README.Debian
   * Added C++ version of comparison routine to examples and made a
     hint in README.Debian what to do
   * Added homepage to long description
   * Applied patch from  Jonathan H N Chin <jhnc%stone@newton.cam.ac.uk>
     (Thanks to Jonathan)
     Closes: #86994
   * Provided example script to enhance finding images which appear three
     times or more. Thanks to Jonathan H N Chin again.
     Closes: #87013
   * Closing old bugs which can not be reproduced any more:
     Closes: #113871 (newer ImageMagic libs seem to work)
 db0a920b9bccb83b6adbd8bd84959090 583 graphics optional findimagedupes_0.1.3-6.dsc
 9de8aa7146824f19c2e68ebf2b1b965d 6701 graphics optional findimagedupes_0.1.3-6.diff.gz
 ad3103d8e0b897cb590a656209f584b9 15502 graphics optional findimagedupes_0.1.3-6_all.deb

Version: GnuPG v1.4.1 (GNU/Linux)


Reply to: