tools/tiffcrop.c:7365: error: Null Dereference
  pointer `sect_buff` last assigned on line 7363 could be null and is dereferenced by call to `_TIFFmemset()` at line 7365, column 5.

tools/tiffcrop.c:7352:1: start of procedure createImageSection()
7350. 
7351. /* Create a buffer to write one section at a time */
7352. static int
      ^
7353. createImageSection(uint32 sectsize, unsigned char **sect_buff_ptr)
7354.   {

tools/tiffcrop.c:7355:3: 
7353. createImageSection(uint32 sectsize, unsigned char **sect_buff_ptr)
7354.   {
7355.   unsigned  char *sect_buff = NULL;
        ^
7356.   unsigned  char *new_buff  = NULL;
7357.   static    uint32  prev_sectsize = 0;

tools/tiffcrop.c:7356:3: 
7354.   {
7355.   unsigned  char *sect_buff = NULL;
7356.   unsigned  char *new_buff  = NULL;
        ^
7357.   static    uint32  prev_sectsize = 0;
7358.   

tools/tiffcrop.c:7357:3: 
7355.   unsigned  char *sect_buff = NULL;
7356.   unsigned  char *new_buff  = NULL;
7357.   static    uint32  prev_sectsize = 0;
        ^
7358.   
7359.   sect_buff = *sect_buff_ptr;

tools/tiffcrop.c:7359:3: 
7357.   static    uint32  prev_sectsize = 0;
7358.   
7359.   sect_buff = *sect_buff_ptr;
        ^
7360. 
7361.   if (!sect_buff)

tools/tiffcrop.c:7361:8: Taking true branch
7359.   sect_buff = *sect_buff_ptr;
7360. 
7361.   if (!sect_buff)
             ^
7362.     {
7363.     sect_buff = (unsigned char *)limitMalloc(sectsize);

tools/tiffcrop.c:7363:5: 
7361.   if (!sect_buff)
7362.     {
7363.     sect_buff = (unsigned char *)limitMalloc(sectsize);
          ^
7364.     *sect_buff_ptr = sect_buff;
7365.     _TIFFmemset(sect_buff, 0, sectsize);

tools/tiffcrop.c:629:1: start of procedure limitMalloc()
  627.  * This custom malloc function enforce a maximum allocation size
  628.  */
  629. static void* limitMalloc(tmsize_t s)
       ^
  630. {
  631.   if (maxMalloc && (s > maxMalloc)) {

tools/tiffcrop.c:631:7: Taking true branch
  629. static void* limitMalloc(tmsize_t s)
  630. {
  631.   if (maxMalloc && (s > maxMalloc)) {
             ^
  632.     fprintf(stderr, "MemoryLimitError: allocation of " TIFF_UINT64_FORMAT " bytes is forbidden. Limit is " TIFF_UINT64_FORMAT ".\n",
  633.             (uint64)s, (uint64)maxMalloc);

tools/tiffcrop.c:631:21: Taking true branch
  629. static void* limitMalloc(tmsize_t s)
  630. {
  631.   if (maxMalloc && (s > maxMalloc)) {
                           ^
  632.     fprintf(stderr, "MemoryLimitError: allocation of " TIFF_UINT64_FORMAT " bytes is forbidden. Limit is " TIFF_UINT64_FORMAT ".\n",
  633.             (uint64)s, (uint64)maxMalloc);

tools/tiffcrop.c:632:5: 
  630. {
  631.   if (maxMalloc && (s > maxMalloc)) {
  632.     fprintf(stderr, "MemoryLimitError: allocation of " TIFF_UINT64_FORMAT " bytes is forbidden. Limit is " TIFF_UINT64_FORMAT ".\n",
           ^
  633.             (uint64)s, (uint64)maxMalloc);
  634.     fprintf(stderr, "                  use -k option to change limit.\n"); return NULL;

tools/tiffcrop.c:634:5: 
  632.     fprintf(stderr, "MemoryLimitError: allocation of " TIFF_UINT64_FORMAT " bytes is forbidden. Limit is " TIFF_UINT64_FORMAT ".\n",
  633.             (uint64)s, (uint64)maxMalloc);
  634.     fprintf(stderr, "                  use -k option to change limit.\n"); return NULL;
           ^
  635.   }
  636.   return _TIFFmalloc(s);

tools/tiffcrop.c:634:76: 
  632.     fprintf(stderr, "MemoryLimitError: allocation of " TIFF_UINT64_FORMAT " bytes is forbidden. Limit is " TIFF_UINT64_FORMAT ".\n",
  633.             (uint64)s, (uint64)maxMalloc);
  634.     fprintf(stderr, "                  use -k option to change limit.\n"); return NULL;
                                                                                  ^
  635.   }
  636.   return _TIFFmalloc(s);

tools/tiffcrop.c:637:1: return from a call to limitMalloc
  635.   }
  636.   return _TIFFmalloc(s);
  637. }
       ^
  638. 
  639. 

tools/tiffcrop.c:7364:5: 
7362.     {
7363.     sect_buff = (unsigned char *)limitMalloc(sectsize);
7364.     *sect_buff_ptr = sect_buff;
          ^
7365.     _TIFFmemset(sect_buff, 0, sectsize);
7366.     }

tools/tiffcrop.c:7365:5: 
7363.     sect_buff = (unsigned char *)limitMalloc(sectsize);
7364.     *sect_buff_ptr = sect_buff;
7365.     _TIFFmemset(sect_buff, 0, sectsize);
          ^
7366.     }
7367.   else

libtiff/tif_unix.c:337:1: start of procedure _TIFFmemset()
  335. }
  336. 
  337. void
       ^
  338. _TIFFmemset(void* p, int v, tmsize_t c)
  339. {

libtiff/tif_unix.c:340:2: 
  338. _TIFFmemset(void* p, int v, tmsize_t c)
  339. {
  340. 	memset(p, v, (size_t) c);
        ^
  341. }
  342. 

libtiff/tif_unix.c:341:1: return from a call to _TIFFmemset
  339. {
  340. 	memset(p, v, (size_t) c);
  341. }
       ^
  342. 
  343. void
