libavformat/utils.c:2609: error: Null Dereference
  pointer `this_pktl` last assigned on line 2608 could be null and is dereferenced at line 2609, column 9.

libavformat/utils.c:2598:1: start of procedure av_interleave_packet_per_dts()
2596. }
2597. 
2598. int av_interleave_packet_per_dts(AVFormatContext *s, AVPacket *out, AVPacket *pkt, int flush){
      ^
2599.     AVPacketList *pktl, **next_point, *this_pktl;
2600.     int stream_count=0;

libavformat/utils.c:2600:5: 
2598. int av_interleave_packet_per_dts(AVFormatContext *s, AVPacket *out, AVPacket *pkt, int flush){
2599.     AVPacketList *pktl, **next_point, *this_pktl;
2600.     int stream_count=0;
          ^
2601.     int streams[MAX_STREAMS];
2602. 

libavformat/utils.c:2603:8: Taking true branch
2601.     int streams[MAX_STREAMS];
2602. 
2603.     if(pkt){
             ^
2604.         AVStream *st= s->streams[ pkt->stream_index];
2605. 

libavformat/utils.c:2604:9: 
2602. 
2603.     if(pkt){
2604.         AVStream *st= s->streams[ pkt->stream_index];
              ^
2605. 
2606. //        assert(pkt->destruct != av_destruct_packet); //FIXME

libavformat/utils.c:2608:9: 
2606. //        assert(pkt->destruct != av_destruct_packet); //FIXME
2607. 
2608.         this_pktl = av_mallocz(sizeof(AVPacketList));
              ^
2609.         this_pktl->pkt= *pkt;
2610.         if(pkt->destruct == av_destruct_packet)

libavutil/mem.c:132:1: start of procedure av_mallocz()
  130. }
  131. 
  132. void *av_mallocz(unsigned int size)
       ^
  133. {
  134.     void *ptr = av_malloc(size);

libavutil/mem.c:134:5: 
  132. void *av_mallocz(unsigned int size)
  133. {
  134.     void *ptr = av_malloc(size);
           ^
  135.     if (ptr)
  136.         memset(ptr, 0, size);

libavutil/mem.c:42:1: start of procedure av_malloc()
    40.    linker will do it automatically */
    41. 
    42. void *av_malloc(unsigned int size)
        ^
    43. {
    44.     void *ptr;

libavutil/mem.c:50:8: Taking false branch
    48. 
    49.     /* let's disallow possible ambiguous cases */
    50.     if(size > (INT_MAX-16) )
               ^
    51.         return NULL;
    52. 

libavutil/mem.c:61:5: Skipping memalign(): method has no implementation
    59.     ((char*)ptr)[-1]= diff;
    60. #elif defined (HAVE_MEMALIGN)
    61.     ptr = memalign(16,size);
            ^
    62.     /* Why 64?
    63.        Indeed, we should align it:

libavutil/mem.c:91:5: 
    89.     ptr = malloc(size);
    90. #endif
    91.     return ptr;
            ^
    92. }
    93. 

libavutil/mem.c:92:1: return from a call to av_malloc
    90. #endif
    91.     return ptr;
    92. }
        ^
    93. 
    94. void *av_realloc(void *ptr, unsigned int size)

libavutil/mem.c:135:9: Taking false branch
  133. {
  134.     void *ptr = av_malloc(size);
  135.     if (ptr)
               ^
  136.         memset(ptr, 0, size);
  137.     return ptr;

libavutil/mem.c:137:5: 
  135.     if (ptr)
  136.         memset(ptr, 0, size);
  137.     return ptr;
           ^
  138. }
  139. 

libavutil/mem.c:138:1: return from a call to av_mallocz
  136.         memset(ptr, 0, size);
  137.     return ptr;
  138. }
       ^
  139. 
  140. char *av_strdup(const char *s)

libavformat/utils.c:2609:9: 
2607. 
2608.         this_pktl = av_mallocz(sizeof(AVPacketList));
2609.         this_pktl->pkt= *pkt;
              ^
2610.         if(pkt->destruct == av_destruct_packet)
2611.             pkt->destruct= NULL; // not shared -> must keep original from being freed
