diff options
author | scuri <scuri> | 2009-09-29 21:26:38 +0000 |
---|---|---|
committer | scuri <scuri> | 2009-09-29 21:26:38 +0000 |
commit | 9a5e93213e08601a58725f44035ac622fb68e849 (patch) | |
tree | fd8f644b149637a79c4ab73b5eef141fce1b0ac2 /src | |
parent | d2c116c0adc98b18124b6c3cbf2b839d5719444f (diff) |
*** empty log message ***
Diffstat (limited to 'src')
-rw-r--r-- | src/im_converttype.cpp | 4 | ||||
-rw-r--r-- | src/libtiff/tif_dirwrite.c | 11 | ||||
-rw-r--r-- | src/libtiff/tif_write.c | 4 | ||||
-rw-r--r-- | src/libtiff/tiffvers.h | 4 |
4 files changed, 9 insertions, 14 deletions
diff --git a/src/im_converttype.cpp b/src/im_converttype.cpp index 0c3d801..ee69b6f 100644 --- a/src/im_converttype.cpp +++ b/src/im_converttype.cpp @@ -2,7 +2,7 @@ * \brief Image Data Type Conversion * * See Copyright Notice in im_lib.h - * $Id: im_converttype.cpp,v 1.2 2008/11/18 20:38:21 scuri Exp $ + * $Id: im_converttype.cpp,v 1.3 2009/09/29 21:30:57 scuri Exp $ */ #include "im.h" @@ -72,7 +72,7 @@ inline int iIntMax() template <class T> inline T iAbs(const T& v) { - if (v <= 0) + if (v < 0) return -1*v; return v; } diff --git a/src/libtiff/tif_dirwrite.c b/src/libtiff/tif_dirwrite.c index 7d5ca71..b04b73a 100644 --- a/src/libtiff/tif_dirwrite.c +++ b/src/libtiff/tif_dirwrite.c @@ -1,4 +1,4 @@ -/* $Id: tif_dirwrite.c,v 1.2 2009/08/21 04:01:59 scuri Exp $ */ +/* $Id: tif_dirwrite.c,v 1.3 2009/09/29 21:26:38 scuri Exp $ */ /* * Copyright (c) 1988-1997 Sam Leffler @@ -100,8 +100,6 @@ _TIFFWriteDirectory(TIFF* tif, int done) */ if (done) { - tsize_t orig_rawcc = tif->tif_rawcc; - if (tif->tif_flags & TIFF_POSTENCODE) { tif->tif_flags &= ~TIFF_POSTENCODE; if (!(*tif->tif_postencode)(tif)) { @@ -114,12 +112,9 @@ _TIFFWriteDirectory(TIFF* tif, int done) (*tif->tif_close)(tif); /* shutdown encoder */ /* * Flush any data that might have been written - * by the compression close+cleanup routines. But - * be careful not to write stuff if we didn't add data - * in the previous steps as the "rawcc" data may well be - * a previously read tile/strip in mixed read/write mode. + * by the compression close+cleanup routines. */ - if (tif->tif_rawcc > 0 && tif->tif_rawcc != orig_rawcc + if (tif->tif_rawcc > 0 && (tif->tif_flags & TIFF_BEENWRITING) != 0 && !TIFFFlushData1(tif)) { TIFFErrorExt(tif->tif_clientdata, tif->tif_name, diff --git a/src/libtiff/tif_write.c b/src/libtiff/tif_write.c index 0d589b5..58fc4b4 100644 --- a/src/libtiff/tif_write.c +++ b/src/libtiff/tif_write.c @@ -1,4 +1,4 @@ -/* $Id: tif_write.c,v 1.2 2009/08/21 04:01:59 scuri Exp $ */ +/* $Id: tif_write.c,v 1.3 2009/09/29 21:26:39 scuri Exp $ */ /* * Copyright (c) 1988-1997 Sam Leffler @@ -630,7 +630,7 @@ TIFFAppendToStrip(TIFF* tif, tstrip_t strip, tidata_t data, tsize_t cc) if( td->td_stripbytecount[strip] != 0 && td->td_stripoffset[strip] != 0 - && (tsize_t) td->td_stripbytecount[strip] >= cc ) + && td->td_stripbytecount[strip] >= cc ) { /* * There is already tile data on disk, and the new tile diff --git a/src/libtiff/tiffvers.h b/src/libtiff/tiffvers.h index aec110d..c4693f4 100644 --- a/src/libtiff/tiffvers.h +++ b/src/libtiff/tiffvers.h @@ -1,4 +1,4 @@ -#define TIFFLIB_VERSION_STR "LIBTIFF, Version 3.9.0\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc." +#define TIFFLIB_VERSION_STR "LIBTIFF, Version 3.9.1\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc." /* * This define can be used in code that requires * compilation-related definitions specific to a @@ -6,4 +6,4 @@ * version checking should be done based on the * string returned by TIFFGetVersion. */ -#define TIFFLIB_VERSION 20090820 +#define TIFFLIB_VERSION 20090828 |