ports/114367: Fix crash on JPEG metadata exceptions in Gwenview

Michael Nottebrock lofi at FreeBSD.org
Fri Jul 6 19:30:04 UTC 2007


>Number:         114367
>Category:       ports
>Synopsis:       Fix crash on JPEG metadata exceptions in Gwenview
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jul 06 19:30:04 GMT 2007
>Closed-Date:
>Last-Modified:
>Originator:     Michael Nottebrock
>Release:        FreeBSD 5.5-RELEASE-p11 i386
>Organization:
>Environment:
System: FreeBSD kiste 5.5-RELEASE-p11 FreeBSD 5.5-RELEASE-p11 #4: Wed May 2 13:59:49 CEST 2007 root at kiste:/usr/obj/usr/src/sys/KISTE-SMP i386


	
>Description:
	Gwenview 1.4.1 as distributed contains a bug that can cause
	crashes when invalid JPEG metadata is encountered.
>How-To-Repeat:
	http://bugs.kde.org/show_bug.cgi?id=138467
>Fix:

	The attached patch fixes the problem (Obtained from: KDE SVN).

--- gwenview.diff begins here ---
Index: Makefile
===================================================================
RCS file: /home/pcvs/ports/graphics/gwenview/Makefile,v
retrieving revision 1.23
diff -u -r1.23 Makefile
--- Makefile	19 May 2007 20:09:29 -0000	1.23
+++ Makefile	6 Jul 2007 16:55:55 -0000
@@ -7,7 +7,7 @@
 
 PORTNAME=	gwenview
 PORTVERSION=	1.4.1
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	graphics kde
 MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
 MASTER_SITE_SUBDIR=	${PORTNAME}
Index: files/patch-src-imageutils-jpegcontent.cpp
===================================================================
RCS file: files/patch-src-imageutils-jpegcontent.cpp
diff -N files/patch-src-imageutils-jpegcontent.cpp
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ files/patch-src-imageutils-jpegcontent.cpp	6 Jul 2007 16:55:55 -0000
@@ -0,0 +1,15 @@
+--- src/imageutils/jpegcontent.cpp.orig	Fri Jul  6 18:37:46 2007
++++ src/imageutils/jpegcontent.cpp	Fri Jul  6 18:38:24 2007
+@@ -255,11 +255,11 @@
+ 	Exiv2::Image::AutoPtr image;
+ 	try {
+ 		image = Exiv2::ImageFactory::open((unsigned char*)data.data(), data.size());
++	image->readMetadata();
+ 	} catch (Exiv2::Error&) {
+ 		kdError() << "Could not load image with Exiv2\n";
+ 		return false;
+ 	}
+-	image->readMetadata();
+ 
+ 	d->mExifData = image->exifData();
+ 	d->mComment = QString::fromUtf8( image->comment().c_str() );
--- gwenview.diff ends here ---


>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list