libavformat/matroskadec.c:956: error: Memory Leak
  memory dynamically allocated by call to `av_realloc()` at line 956, column 24 is not reachable after line 956, column 13.

libavformat/matroskadec.c:935:1: start of procedure matroska_decode_buffer()
933. }
934. 
935. static int matroska_decode_buffer(uint8_t** buf, int* buf_size,
     ^
936.                                   MatroskaTrack *track)
937. {

libavformat/matroskadec.c:938:5: 
936.                                   MatroskaTrack *track)
937. {
938.     MatroskaTrackEncoding *encodings = track->encodings.elem;
         ^
939.     uint8_t* data = *buf;
940.     int isize = *buf_size;

libavformat/matroskadec.c:939:5: 
937. {
938.     MatroskaTrackEncoding *encodings = track->encodings.elem;
939.     uint8_t* data = *buf;
         ^
940.     int isize = *buf_size;
941.     uint8_t* pkt_data = NULL;

libavformat/matroskadec.c:940:5: 
938.     MatroskaTrackEncoding *encodings = track->encodings.elem;
939.     uint8_t* data = *buf;
940.     int isize = *buf_size;
         ^
941.     uint8_t* pkt_data = NULL;
942.     uint8_t* newpktdata;

libavformat/matroskadec.c:941:5: 
939.     uint8_t* data = *buf;
940.     int isize = *buf_size;
941.     uint8_t* pkt_data = NULL;
         ^
942.     uint8_t* newpktdata;
943.     int pkt_size = isize;

libavformat/matroskadec.c:943:5: 
941.     uint8_t* pkt_data = NULL;
942.     uint8_t* newpktdata;
943.     int pkt_size = isize;
         ^
944.     int result = 0;
945.     int olen;

libavformat/matroskadec.c:944:5: 
942.     uint8_t* newpktdata;
943.     int pkt_size = isize;
944.     int result = 0;
         ^
945.     int olen;
946. 

libavformat/matroskadec.c:947:9: Taking false branch
945.     int olen;
946. 
947.     if (pkt_size >= 10000000)
             ^
948.         return -1;
949. 

libavformat/matroskadec.c:950:5: 
948.         return -1;
949. 
950.     switch (encodings[0].compression.algo) {
         ^
951.     case MATROSKA_TRACK_ENCODING_COMP_HEADERSTRIP:
952.         return encodings[0].compression.settings.size;

libavformat/matroskadec.c:951:5: Switch condition is false. Skipping switch case
949. 
950.     switch (encodings[0].compression.algo) {
951.     case MATROSKA_TRACK_ENCODING_COMP_HEADERSTRIP:
         ^
952.         return encodings[0].compression.settings.size;
953.     case MATROSKA_TRACK_ENCODING_COMP_LZO:

libavformat/matroskadec.c:953:5: Switch condition is true. Entering switch case
951.     case MATROSKA_TRACK_ENCODING_COMP_HEADERSTRIP:
952.         return encodings[0].compression.settings.size;
953.     case MATROSKA_TRACK_ENCODING_COMP_LZO:
         ^
954.         do {
955.             olen = pkt_size *= 3;

libavformat/matroskadec.c:955:13: 
953.     case MATROSKA_TRACK_ENCODING_COMP_LZO:
954.         do {
955.             olen = pkt_size *= 3;
                 ^
956.             pkt_data = av_realloc(pkt_data, pkt_size+AV_LZO_OUTPUT_PADDING);
957.             result = av_lzo1x_decode(pkt_data, &olen, data, &isize);

libavformat/matroskadec.c:956:13: 
954.         do {
955.             olen = pkt_size *= 3;
956.             pkt_data = av_realloc(pkt_data, pkt_size+AV_LZO_OUTPUT_PADDING);
                 ^
957.             result = av_lzo1x_decode(pkt_data, &olen, data, &isize);
958.         } while (result==AV_LZO_OUTPUT_FULL && pkt_size<10000000);

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

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

libavutil/mem.c:133:5: 
  131.     return (char*)realloc((char*)ptr - diff, size + diff) + diff;
  132. #else
  133.     return realloc(ptr, size);
           ^
  134. #endif
  135. }

libavutil/mem.c:135:1: return from a call to av_realloc
  133.     return realloc(ptr, size);
  134. #endif
  135. }
       ^
  136. 
  137. void av_free(void *ptr)

libavformat/matroskadec.c:957:13: Skipping av_lzo1x_decode(): empty list of specs
955.             olen = pkt_size *= 3;
956.             pkt_data = av_realloc(pkt_data, pkt_size+AV_LZO_OUTPUT_PADDING);
957.             result = av_lzo1x_decode(pkt_data, &olen, data, &isize);
                 ^
958.         } while (result==AV_LZO_OUTPUT_FULL && pkt_size<10000000);
959.         if (result)

libavformat/matroskadec.c:958:18: Loop condition is true. Entering loop body
956.             pkt_data = av_realloc(pkt_data, pkt_size+AV_LZO_OUTPUT_PADDING);
957.             result = av_lzo1x_decode(pkt_data, &olen, data, &isize);
958.         } while (result==AV_LZO_OUTPUT_FULL && pkt_size<10000000);
                      ^
959.         if (result)
960.             goto failed;

libavformat/matroskadec.c:958:48: Loop condition is true. Entering loop body
956.             pkt_data = av_realloc(pkt_data, pkt_size+AV_LZO_OUTPUT_PADDING);
957.             result = av_lzo1x_decode(pkt_data, &olen, data, &isize);
958.         } while (result==AV_LZO_OUTPUT_FULL && pkt_size<10000000);
                                                    ^
959.         if (result)
960.             goto failed;

libavformat/matroskadec.c:955:13: 
953.     case MATROSKA_TRACK_ENCODING_COMP_LZO:
954.         do {
955.             olen = pkt_size *= 3;
                 ^
956.             pkt_data = av_realloc(pkt_data, pkt_size+AV_LZO_OUTPUT_PADDING);
957.             result = av_lzo1x_decode(pkt_data, &olen, data, &isize);

libavformat/matroskadec.c:956:13: 
954.         do {
955.             olen = pkt_size *= 3;
956.             pkt_data = av_realloc(pkt_data, pkt_size+AV_LZO_OUTPUT_PADDING);
                 ^
957.             result = av_lzo1x_decode(pkt_data, &olen, data, &isize);
958.         } while (result==AV_LZO_OUTPUT_FULL && pkt_size<10000000);

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

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

libavutil/mem.c:125:9: 
  123.     /* let's disallow possible ambiguous cases */
  124.     if(size > (INT_MAX-16) )
  125.         return NULL;
               ^
  126. 
  127. #if CONFIG_MEMALIGN_HACK

libavutil/mem.c:135:1: return from a call to av_realloc
  133.     return realloc(ptr, size);
  134. #endif
  135. }
       ^
  136. 
  137. void av_free(void *ptr)
