libtiff/tif_jpeg.c:763: error: Memory Leak
  memory dynamically allocated by call to `_TIFFmalloc()` at line 751, column 11 is not reachable after line 763, column 7.

libtiff/tif_jpeg.c:711:1: start of procedure JPEGFixupTagsSubsampling()
709. #ifdef CHECK_JPEG_YCBCR_SUBSAMPLING
710. 
711. static void
     ^
712. JPEGFixupTagsSubsampling(TIFF* tif)
713. {

libtiff/tif_jpeg.c:734:2: 
732. 	 * Joris Van Damme, May 2007
733. 	 */
734. 	static const char module[] = "JPEGFixupTagsSubsampling";
      ^
735. 	struct JPEGFixupTagsSubsamplingData m;
736. 

libtiff/tif_jpeg.c:737:9: 
735. 	struct JPEGFixupTagsSubsamplingData m;
736. 
737.         _TIFFFillStriles( tif );
             ^
738.         
739.         if( tif->tif_dir.td_stripbytecount == NULL

libtiff/tif_dirread.c:5573:1: start of procedure _TIFFFillStriles()
  5571. }
  5572. 
  5573. int _TIFFFillStriles( TIFF *tif )
        ^
  5574. {
  5575.     return _TIFFFillStrilesInternal( tif, 1 );

libtiff/tif_dirread.c:5575:5: 
  5573. int _TIFFFillStriles( TIFF *tif )
  5574. {
  5575.     return _TIFFFillStrilesInternal( tif, 1 );
            ^
  5576. }
  5577. 

libtiff/tif_dirread.c:5578:1: start of procedure _TIFFFillStrilesInternal()
    5576. }
    5577. 
    5578. static int _TIFFFillStrilesInternal( TIFF *tif, int loadStripByteCount )
          ^
    5579. {
    5580. #if defined(DEFER_STRILE_LOAD)

libtiff/tif_dirread.c:5621:9: 
    5619.         return return_value;
    5620. #else /* !defined(DEFER_STRILE_LOAD) */
    5621.         (void) tif;
                  ^
    5622.         (void) loadStripByteCount;
    5623.         return 1;

libtiff/tif_dirread.c:5622:9: 
    5620. #else /* !defined(DEFER_STRILE_LOAD) */
    5621.         (void) tif;
    5622.         (void) loadStripByteCount;
                  ^
    5623.         return 1;
    5624. #endif 

libtiff/tif_dirread.c:5623:9: 
    5621.         (void) tif;
    5622.         (void) loadStripByteCount;
    5623.         return 1;
                  ^
    5624. #endif 
    5625. }

libtiff/tif_dirread.c:5625:1: return from a call to _TIFFFillStrilesInternal
    5623.         return 1;
    5624. #endif 
    5625. }
          ^
    5626. 
    5627. 

libtiff/tif_dirread.c:5576:1: return from a call to _TIFFFillStriles
  5574. {
  5575.     return _TIFFFillStrilesInternal( tif, 1 );
  5576. }
        ^
  5577. 
  5578. static int _TIFFFillStrilesInternal( TIFF *tif, int loadStripByteCount )

libtiff/tif_jpeg.c:739:13: Taking false branch
737.         _TIFFFillStriles( tif );
738.         
739.         if( tif->tif_dir.td_stripbytecount == NULL
                 ^
740.             || tif->tif_dir.td_stripoffset == NULL
741.             || tif->tif_dir.td_stripbytecount[0] == 0 )

libtiff/tif_jpeg.c:740:16: Taking false branch
738.         
739.         if( tif->tif_dir.td_stripbytecount == NULL
740.             || tif->tif_dir.td_stripoffset == NULL
                    ^
741.             || tif->tif_dir.td_stripbytecount[0] == 0 )
742.         {

libtiff/tif_jpeg.c:741:16: Taking false branch
739.         if( tif->tif_dir.td_stripbytecount == NULL
740.             || tif->tif_dir.td_stripoffset == NULL
741.             || tif->tif_dir.td_stripbytecount[0] == 0 )
                    ^
742.         {
743.             /* Do not even try to check if the first strip/tile does not

libtiff/tif_jpeg.c:749:2: 
747.         }
748. 
749. 	m.tif=tif;
      ^
750. 	m.buffersize=2048;
751. 	m.buffer=_TIFFmalloc(m.buffersize);

libtiff/tif_jpeg.c:750:2: 
748. 
749. 	m.tif=tif;
750. 	m.buffersize=2048;
      ^
751. 	m.buffer=_TIFFmalloc(m.buffersize);
752. 	if (m.buffer==NULL)

libtiff/tif_jpeg.c:751:2: 
749. 	m.tif=tif;
750. 	m.buffersize=2048;
751. 	m.buffer=_TIFFmalloc(m.buffersize);
      ^
752. 	if (m.buffer==NULL)
753. 	{

libtiff/tif_unix.c:310:1: start of procedure _TIFFmalloc()
  308. #endif
  309. 
  310. void*
       ^
  311. _TIFFmalloc(tmsize_t s)
  312. {

libtiff/tif_unix.c:313:13: Taking false branch
  311. _TIFFmalloc(tmsize_t s)
  312. {
  313.         if (s == 0)
                   ^
  314.                 return ((void *) NULL);
  315. 

libtiff/tif_unix.c:316:2: 
  314.                 return ((void *) NULL);
  315. 
  316. 	return (malloc((size_t) s));
        ^
  317. }
  318. 

libtiff/tif_unix.c:317:1: return from a call to _TIFFmalloc
  315. 
  316. 	return (malloc((size_t) s));
  317. }
       ^
  318. 
  319. void

libtiff/tif_jpeg.c:752:6: Taking false branch
750. 	m.buffersize=2048;
751. 	m.buffer=_TIFFmalloc(m.buffersize);
752. 	if (m.buffer==NULL)
          ^
753. 	{
754. 		TIFFWarningExt(tif->tif_clientdata,module,

libtiff/tif_jpeg.c:758:2: 
756. 		return;
757. 	}
758. 	m.buffercurrentbyte=NULL;
      ^
759. 	m.bufferbytesleft=0;
760. 	m.fileoffset=tif->tif_dir.td_stripoffset[0];

libtiff/tif_jpeg.c:759:2: 
757. 	}
758. 	m.buffercurrentbyte=NULL;
759. 	m.bufferbytesleft=0;
      ^
760. 	m.fileoffset=tif->tif_dir.td_stripoffset[0];
761. 	m.filepositioned=0;

libtiff/tif_jpeg.c:760:2: 
758. 	m.buffercurrentbyte=NULL;
759. 	m.bufferbytesleft=0;
760. 	m.fileoffset=tif->tif_dir.td_stripoffset[0];
      ^
761. 	m.filepositioned=0;
762. 	m.filebytesleft=tif->tif_dir.td_stripbytecount[0];

libtiff/tif_jpeg.c:761:2: 
759. 	m.bufferbytesleft=0;
760. 	m.fileoffset=tif->tif_dir.td_stripoffset[0];
761. 	m.filepositioned=0;
      ^
762. 	m.filebytesleft=tif->tif_dir.td_stripbytecount[0];
763. 	if (!JPEGFixupTagsSubsamplingSec(&m))

libtiff/tif_jpeg.c:762:2: 
760. 	m.fileoffset=tif->tif_dir.td_stripoffset[0];
761. 	m.filepositioned=0;
762. 	m.filebytesleft=tif->tif_dir.td_stripbytecount[0];
      ^
763. 	if (!JPEGFixupTagsSubsamplingSec(&m))
764. 		TIFFWarningExt(tif->tif_clientdata,module,

libtiff/tif_jpeg.c:763:7: Skipping JPEGFixupTagsSubsamplingSec(): empty list of specs
761. 	m.filepositioned=0;
762. 	m.filebytesleft=tif->tif_dir.td_stripbytecount[0];
763. 	if (!JPEGFixupTagsSubsamplingSec(&m))
           ^
764. 		TIFFWarningExt(tif->tif_clientdata,module,
765. 		    "Unable to auto-correct subsampling values, likely corrupt JPEG compressed data in first strip/tile; auto-correcting skipped");
