summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrank Warmerdam <warmerdam@pobox.com>2004-10-01 18:52:58 +0000
committerFrank Warmerdam <warmerdam@pobox.com>2004-10-01 18:52:58 +0000
commit803f8ad8dc63c8642a2fc04e5bb1ecf5e081c85e (patch)
tree51e37f7f633343fd97fff950b12706919fa52795
parent453ae1a8e4e53964d2079bfa4cd99046c6d871e6 (diff)
downloadlibtiff-git-803f8ad8dc63c8642a2fc04e5bb1ecf5e081c85e.tar.gz
Added a more informative message if a BigTIFF file is opened.
-rw-r--r--libtiff/tif_open.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/libtiff/tif_open.c b/libtiff/tif_open.c
index dca1f583..dafd86a0 100644
--- a/libtiff/tif_open.c
+++ b/libtiff/tif_open.c
@@ -1,4 +1,4 @@
-/* $Id: tif_open.c,v 1.20 2004-09-08 18:01:29 dron Exp $ */
+/* $Id: tif_open.c,v 1.21 2004-10-01 18:52:58 fwarmerdam Exp $ */
/*
* Copyright (c) 1988-1997 Sam Leffler
@@ -360,6 +360,12 @@ TIFFClientOpen(
* Note that this isn't actually a version number, it's a
* magic number that doesn't change (stupid).
*/
+ if (tif->tif_header.tiff_version == TIFF_BIGTIFF_VERSION) {
+ TIFFError(name,
+ "This is a BigTIFF file. This format not supported\n"
+ "by this version of libtiff." );
+ goto bad;
+ }
if (tif->tif_header.tiff_version != TIFF_VERSION) {
TIFFError(name,
"Not a TIFF file, bad version number %d (0x%x)",