summaryrefslogtreecommitdiff
path: root/src/libtiff/tif_open.c
diff options
context:
space:
mode:
authorscuri <scuri>2009-08-21 04:01:59 +0000
committerscuri <scuri>2009-08-21 04:01:59 +0000
commit6c39dd63dc4f91b358155c173a2cfdf4c6c5af3e (patch)
tree61b709d64e58613bc06b2c2947023d707b764eba /src/libtiff/tif_open.c
parent59cda2efbd34938420a506daa60ab47168116484 (diff)
*** empty log message ***
Diffstat (limited to 'src/libtiff/tif_open.c')
-rw-r--r--src/libtiff/tif_open.c19
1 files changed, 12 insertions, 7 deletions
diff --git a/src/libtiff/tif_open.c b/src/libtiff/tif_open.c
index 98b30fa..9020973 100644
--- a/src/libtiff/tif_open.c
+++ b/src/libtiff/tif_open.c
@@ -1,4 +1,4 @@
-/* $Id: tif_open.c,v 1.1 2008/10/17 06:16:07 scuri Exp $ */
+/* $Id: tif_open.c,v 1.2 2009/08/21 04:01:59 scuri Exp $ */
/*
* Copyright (c) 1988-1997 Sam Leffler
@@ -198,7 +198,7 @@ TIFFClientOpen(
*/
tif->tif_flags = FILLORDER_MSB2LSB;
if (m == O_RDONLY )
- tif->tif_flags |= TIFF_MAPPED;
+ tif->tif_flags |= TIFF_MAPPED;
#ifdef STRIPCHOP_DEFAULT
if (m == O_RDONLY || m == O_RDWR)
@@ -307,7 +307,8 @@ TIFFClientOpen(
if (tif->tif_mode & O_TRUNC ||
!ReadOK(tif, &tif->tif_header, sizeof (TIFFHeader))) {
if (tif->tif_mode == O_RDONLY) {
- TIFFErrorExt(tif->tif_clientdata, name, "Cannot read TIFF header");
+ TIFFErrorExt(tif->tif_clientdata, name,
+ "Cannot read TIFF header");
goto bad;
}
/*
@@ -336,7 +337,8 @@ TIFFClientOpen(
TIFFSeekFile( tif, 0, SEEK_SET );
if (!WriteOK(tif, &tif->tif_header, sizeof (TIFFHeader))) {
- TIFFErrorExt(tif->tif_clientdata, name, "Error writing TIFF header");
+ TIFFErrorExt(tif->tif_clientdata, name,
+ "Error writing TIFF header");
goto bad;
}
/*
@@ -350,6 +352,7 @@ TIFFClientOpen(
goto bad;
tif->tif_diroff = 0;
tif->tif_dirlist = NULL;
+ tif->tif_dirlistsize = 0;
tif->tif_dirnumber = 0;
return (tif);
}
@@ -366,10 +369,12 @@ TIFFClientOpen(
tif->tif_header.tiff_magic != MDI_LITTLEENDIAN
#endif
) {
- TIFFErrorExt(tif->tif_clientdata, name, "Not a TIFF or MDI file, bad magic number %d (0x%x)",
+ TIFFErrorExt(tif->tif_clientdata, name,
+ "Not a TIFF or MDI file, bad magic number %d (0x%x)",
#else
) {
- TIFFErrorExt(tif->tif_clientdata, name, "Not a TIFF file, bad magic number %d (0x%x)",
+ TIFFErrorExt(tif->tif_clientdata, name,
+ "Not a TIFF file, bad magic number %d (0x%x)",
#endif
tif->tif_header.tiff_magic,
tif->tif_header.tiff_magic);
@@ -398,7 +403,7 @@ TIFFClientOpen(
TIFFErrorExt(tif->tif_clientdata, name,
"Not a TIFF file, bad version number %d (0x%x)",
tif->tif_header.tiff_version,
- tif->tif_header.tiff_version);
+ tif->tif_header.tiff_version);
goto bad;
}
tif->tif_flags |= TIFF_MYBUFFER;