libavformat/matroskaenc.c:376: error: Memory Leak
  memory dynamically allocated to `return` by call to `av_realloc()` at line 371, column 15 is not reachable after line 376, column 9.

libavformat/matroskaenc.c:367:1: start of procedure mkv_add_cuepoint()
365. }
366. 
367. static int mkv_add_cuepoint(mkv_cues *cues, int stream, int64_t ts, int64_t cluster_pos)
     ^
368. {
369.     mkv_cuepoint *entries = cues->entries;

libavformat/matroskaenc.c:369:5: 
367. static int mkv_add_cuepoint(mkv_cues *cues, int stream, int64_t ts, int64_t cluster_pos)
368. {
369.     mkv_cuepoint *entries = cues->entries;
         ^
370. 
371.     entries = av_realloc(entries, (cues->num_entries + 1) * sizeof(mkv_cuepoint));

libavformat/matroskaenc.c:371:5: 
369.     mkv_cuepoint *entries = cues->entries;
370. 
371.     entries = av_realloc(entries, (cues->num_entries + 1) * sizeof(mkv_cuepoint));
         ^
372.     if (entries == NULL)
373.         return AVERROR(ENOMEM);

libavutil/mem.c:119:1: start of procedure av_realloc()
  117. }
  118. 
  119. void *av_realloc(void *ptr, size_t size)
       ^
  120. {
  121. #if CONFIG_MEMALIGN_HACK

libavutil/mem.c:126:8: Taking false branch
  124. 
  125.     /* let's disallow possible ambiguous cases */
  126.     if(size > (INT_MAX-16) )
              ^
  127.         return NULL;
  128. 

libavutil/mem.c:137:5: 
  135.     return _aligned_realloc(ptr, size, 32);
  136. #else
  137.     return realloc(ptr, size);
           ^
  138. #endif
  139. }

libavutil/mem.c:139:1: return from a call to av_realloc
  137.     return realloc(ptr, size);
  138. #endif
  139. }
       ^
  140. 
  141. void av_free(void *ptr)

libavformat/matroskaenc.c:372:9: Taking false branch
370. 
371.     entries = av_realloc(entries, (cues->num_entries + 1) * sizeof(mkv_cuepoint));
372.     if (entries == NULL)
             ^
373.         return AVERROR(ENOMEM);
374. 

libavformat/matroskaenc.c:375:9: Taking true branch
373.         return AVERROR(ENOMEM);
374. 
375.     if (ts < 0)
             ^
376.         return 0;
377. 

libavformat/matroskaenc.c:376:9: 
374. 
375.     if (ts < 0)
376.         return 0;
             ^
377. 
378.     entries[cues->num_entries  ].pts = ts;
