Sophie

Sophie

distrib > Mandriva > 2007.1 > x86_64 > by-pkgid > 48859f1a03824ce4e7011c765ea26c9c > files > 6

libexif-0.6.13-4.3mdv2007.1.src.rpm

Index: libexif/exif-data.c
===================================================================
RCS file: /cvsroot/libexif/libexif/libexif/exif-data.c,v
retrieving revision 1.89
retrieving revision 1.90
diff -u -r1.89 -r1.90
--- libexif/exif-data.c	9 May 2007 06:09:05 -0000	1.89
+++ libexif/exif-data.c	10 May 2007 14:32:01 -0000	1.90
@@ -179,7 +179,9 @@
 	else
 		doff = offset + 8;
 
-	/* Sanity check */
+	/* Sanity checks */
+	if ((doff + s < doff) || (doff + s < s))
+		return 0;
 	if (size < doff + s)
 		return 0;