libtiff/tif_write.c:411: error: Buffer Overrun S2
  Offset: `tile` Size: [0, +oo].

libtiff/tif_write.c:378:1: <Offset trace>
376.  *     the image on each write (as TIFFWriteScanline does).
377.  */
378. tmsize_t
     ^
379. TIFFWriteEncodedTile(TIFF* tif, uint32 tile, void* data, tmsize_t cc)
380. {

libtiff/tif_write.c:378:1: Parameter `tile`
376.  *     the image on each write (as TIFFWriteScanline does).
377.  */
378. tmsize_t
     ^
379. TIFFWriteEncodedTile(TIFF* tif, uint32 tile, void* data, tmsize_t cc)
380. {

libtiff/tif_write.c:378:1: <Length trace>
376.  *     the image on each write (as TIFFWriteScanline does).
377.  */
378. tmsize_t
     ^
379. TIFFWriteEncodedTile(TIFF* tif, uint32 tile, void* data, tmsize_t cc)
380. {

libtiff/tif_write.c:378:1: Parameter `*tif->tif_dir.td_stripbytecount`
376.  *     the image on each write (as TIFFWriteScanline does).
377.  */
378. tmsize_t
     ^
379. TIFFWriteEncodedTile(TIFF* tif, uint32 tile, void* data, tmsize_t cc)
380. {

libtiff/tif_write.c:411:52: Array access: Offset: tile Size: [0, +oo]
409.             /* so that TIFFAppendToStrip() will detect the overflow when it is called the first */
410.             /* time if the new compressed tile is bigger than the older one. (GDAL #4771) */
411.             if( tif->tif_rawdatasize <= (tmsize_t) td->td_stripbytecount[tile] )
                                                        ^
412.             {
413.                 if( !(TIFFWriteBufferSetup(tif, NULL,
