tools/tiffcrop.c:6691: error: Integer Overflow L2
  ([min(1, `out->tif_dir.td_imagedepth`), 4294967294] + [0, 4294967294-min(1, `out->tif_dir.td_imagedepth`)]):unsigned32 by call to `writeSingleSection`.

tools/tiffcrop.c:6649:1: Parameter `out->tif_dir.td_imagedepth`
6647.   } /* end writeRegions */
6648. 
6649. static int
      ^
6650. writeImageSections(TIFF *in, TIFF *out, struct image_data *image,
6651. 		   struct pagedef *page, struct pageseg *sections,

tools/tiffcrop.c:6691:9: Call
6689. 
6690.   /* call the write routine here instead of outside the loop */
6691.     if (writeSingleSection(in, out, image, dump, width, length, hres, vres, sect_buff))
              ^
6692.       {
6693.       TIFFError("writeImageSections", "Unable to write image section");

tools/tiffcrop.c:6707:1: Parameter `out->tif_dir.td_imagedepth`
  6705.  * original code assumes we are always copying all samples.
  6706.  */
  6707. static int  
        ^
  6708. writeSingleSection(TIFF *in, TIFF *out, struct image_data *image,
  6709.                    struct dump_opts *dump, uint32 width, uint32 length,

tools/tiffcrop.c:6958:7: Call
  6956.     {
  6957.     if (config == PLANARCONFIG_CONTIG)
  6958.       writeBufferToContigStrips (out, sect_buff, length);
              ^
  6959.     else
  6960.       writeBufferToSeparateStrips(out, sect_buff, length, width, spp, dump);

tools/tiffcrop.c:1086:1: Parameter `out->tif_dir.td_imagedepth`
    1084.   }
    1085. 
    1086. static int writeBufferToContigStrips(TIFF* out, uint8* buf, uint32 imagelength)
          ^
    1087.   {
    1088.   uint32 row, nrows, rowsperstrip;

tools/tiffcrop.c:1098:9: Call
    1096. 	     imagelength - row : rowsperstrip;
    1097.     stripsize = TIFFVStripSize(out, nrows);
    1098.     if (TIFFWriteEncodedStrip(out, strip++, buf, stripsize) < 0)
                  ^
    1099.       {
    1100.       TIFFError(TIFFFileName(out), "Error, can't write strip %u", strip - 1);

libtiff/tif_write.c:183:1: Parameter `tif->tif_dir.td_imagedepth`
      181.  * NB: Image length must be setup before writing.
      182.  */
      183. tmsize_t
           ^
      184. TIFFWriteEncodedStrip(TIFF* tif, uint32 strip, void* data, tmsize_t cc)
      185. {

libtiff/tif_write.c:190:7: Call
      188. 	uint16 sample;
      189. 
      190. 	if (!WRITECHECKSTRIPS(tif, module))
                 ^
      191. 		return ((tmsize_t) -1);
      192. 	/*

libtiff/tif_write.c:488:1: Parameter `tif->tif_dir.td_imagedepth`
        486.  * that important information is not changed.
        487.  */
        488. int
             ^
        489. TIFFWriteCheck(TIFF* tif, int tiles, const char* module)
        490. {

libtiff/tif_write.c:533:46: Call
        531. 		}
        532. 	}
        533. 	if (tif->tif_dir.td_stripoffset == NULL && !TIFFSetupStrips(tif)) {
                                                          ^
        534. 		tif->tif_dir.td_nstrips = 0;
        535. 		TIFFErrorExt(tif->tif_clientdata, module, "No space for %s arrays",

libtiff/tif_write.c:448:1: Parameter `tif->tif_dir.td_imagedepth`
          446.     (TIFFFieldSet(tif,f) && (tif)->tif_dir.td_imagelength == 0)
          447. 
          448. int
               ^
          449. TIFFSetupStrips(TIFF* tif)
          450. {

libtiff/tif_write.c:456:29: Call
          454. 		td->td_stripsperimage =
          455. 		    isUnspecified(tif, FIELD_TILEDIMENSIONS) ?
          456. 			td->td_samplesperpixel : TIFFNumberOfTiles(tif);
                                           ^
          457. 	else
          458. 		td->td_stripsperimage =

libtiff/tif_tile.c:140:1: <LHS trace>
138.  * Compute how many tiles are in an image.
139.  */
140. uint32
     ^
141. TIFFNumberOfTiles(TIFF* tif)
142. {

libtiff/tif_tile.c:140:1: Parameter `tif->tif_dir.td_imagedepth`
            138.  * Compute how many tiles are in an image.
            139.  */
            140. uint32
                 ^
            141. TIFFNumberOfTiles(TIFF* tif)
            142. {

libtiff/tif_tile.c:140:1: <RHS trace>
138.  * Compute how many tiles are in an image.
139.  */
140. uint32
     ^
141. TIFFNumberOfTiles(TIFF* tif)
142. {

libtiff/tif_tile.c:140:1: Parameter `tif->tif_dir.td_imagedepth`
            138.  * Compute how many tiles are in an image.
            139.  */
            140. uint32
                 ^
            141. TIFFNumberOfTiles(TIFF* tif)
            142. {

libtiff/tif_tile.c:159:6: Binary operation: ([min(1, out->tif_dir.td_imagedepth), 4294967294] + [0, 4294967294-min(1, out->tif_dir.td_imagedepth)]):unsigned32 by call to `writeSingleSection` 
            157. 	    TIFFhowmany_32(td->td_imagelength, dy),
            158. 	    "TIFFNumberOfTiles"),
            159. 	    TIFFhowmany_32(td->td_imagedepth, dz), "TIFFNumberOfTiles");
                      ^
            160. 	if (td->td_planarconfig == PLANARCONFIG_SEPARATE)
            161. 		ntiles = multiply_32(tif, ntiles, td->td_samplesperpixel,
