Fixes in error messages, as suggested by Bernd Herd.
This commit is contained in:
parent
99f27de21e
commit
b84b0ef102
@ -1,4 +1,4 @@
|
||||
/* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_read.c,v 1.8 2002-07-31 20:52:36 warmerda Exp $ */
|
||||
/* $Id: tif_read.c,v 1.9 2004-07-10 20:04:47 dron Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988-1997 Sam Leffler
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $Id: tif_strip.c,v 1.4 2004-04-30 08:34:44 dron Exp $ */
|
||||
/* $Id: tif_strip.c,v 1.5 2004-07-10 20:04:47 dron Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1991-1997 Sam Leffler
|
||||
@ -44,8 +44,8 @@ TIFFComputeStrip(TIFF* tif, uint32 row, tsample_t sample)
|
||||
if (td->td_planarconfig == PLANARCONFIG_SEPARATE) {
|
||||
if (sample >= td->td_samplesperpixel) {
|
||||
TIFFError(tif->tif_name,
|
||||
"%u: Sample out of range, max %u",
|
||||
sample, td->td_samplesperpixel);
|
||||
"%lu: Sample out of range, max %lu",
|
||||
(u_long) sample, (u_long) td->td_samplesperpixel);
|
||||
return ((tstrip_t) 0);
|
||||
}
|
||||
strip += sample*td->td_stripsperimage;
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_tile.c,v 1.2 2003-11-09 22:04:58 warmerda Exp $ */
|
||||
/* $Id: tif_tile.c,v 1.3 2004-07-10 20:04:47 dron Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1991-1997 Sam Leffler
|
||||
@ -77,24 +77,24 @@ TIFFCheckTile(TIFF* tif, uint32 x, uint32 y, uint32 z, tsample_t s)
|
||||
TIFFDirectory *td = &tif->tif_dir;
|
||||
|
||||
if (x >= td->td_imagewidth) {
|
||||
TIFFError(tif->tif_name, "Col %ld out of range, max %lu",
|
||||
(long) x, (u_long) td->td_imagewidth);
|
||||
TIFFError(tif->tif_name, "%lu: Col out of range, max %lu",
|
||||
(u_long) x, (u_long) td->td_imagewidth);
|
||||
return (0);
|
||||
}
|
||||
if (y >= td->td_imagelength) {
|
||||
TIFFError(tif->tif_name, "Row %ld out of range, max %lu",
|
||||
(long) y, (u_long) td->td_imagelength);
|
||||
TIFFError(tif->tif_name, "%lu: Row out of range, max %lu",
|
||||
(u_long) y, (u_long) td->td_imagelength);
|
||||
return (0);
|
||||
}
|
||||
if (z >= td->td_imagedepth) {
|
||||
TIFFError(tif->tif_name, "Depth %ld out of range, max %lu",
|
||||
(long) z, (u_long) td->td_imagedepth);
|
||||
TIFFError(tif->tif_name, "%lu: Depth out of range, max %lu",
|
||||
(u_long) z, (u_long) td->td_imagedepth);
|
||||
return (0);
|
||||
}
|
||||
if (td->td_planarconfig == PLANARCONFIG_SEPARATE &&
|
||||
s >= td->td_samplesperpixel) {
|
||||
TIFFError(tif->tif_name, "Sample %d out of range, max %u",
|
||||
(int) s, td->td_samplesperpixel);
|
||||
TIFFError(tif->tif_name, "%lu: Sample out of range, max %lu",
|
||||
(u_long) s, (u_long) td->td_samplesperpixel);
|
||||
return (0);
|
||||
}
|
||||
return (1);
|
||||
|
Loading…
Reference in New Issue
Block a user