libavformat/movenc.c:1104: error: Null Dereference
  pointer `ctts_entries` last assigned on line 1103 could be null and is dereferenced at line 1104, column 5.

libavformat/movenc.c:1096:1: start of procedure mov_write_ctts_tag()
1094. }
1095. 
1096. static int mov_write_ctts_tag(AVIOContext *pb, MOVTrack *track)
      ^
1097. {
1098.     MOVStts *ctts_entries;

libavformat/movenc.c:1099:5: 
1097. {
1098.     MOVStts *ctts_entries;
1099.     uint32_t entries = 0;
          ^
1100.     uint32_t atom_size;
1101.     int i;

libavformat/movenc.c:1103:5: 
1101.     int i;
1102. 
1103.     ctts_entries = av_malloc((track->entry + 1) * sizeof(*ctts_entries)); /* worst case */
          ^
1104.     ctts_entries[0].count = 1;
1105.     ctts_entries[0].duration = track->cluster[0].cts;

libavutil/mem.c:61:1: start of procedure av_malloc()
  59.  * linker will do it automatically. */
  60. 
  61. void *av_malloc(size_t size)
      ^
  62. {
  63.     void *ptr = NULL;

libavutil/mem.c:63:5: 
  61. void *av_malloc(size_t size)
  62. {
  63.     void *ptr = NULL;
          ^
  64. #if CONFIG_MEMALIGN_HACK
  65.     long diff;

libavutil/mem.c:69:9: Taking true branch
  67. 
  68.     /* let's disallow possible ambiguous cases */
  69.     if (size > (INT_MAX - 32) || !size)
              ^
  70.         return NULL;
  71. 

libavutil/mem.c:70:9: 
  68.     /* let's disallow possible ambiguous cases */
  69.     if (size > (INT_MAX - 32) || !size)
  70.         return NULL;
              ^
  71. 
  72. #if CONFIG_MEMALIGN_HACK

libavutil/mem.c:114:1: return from a call to av_malloc
  112. #endif
  113.     return ptr;
  114. }
       ^
  115. 
  116. void *av_realloc(void *ptr, size_t size)

libavformat/movenc.c:1104:5: 
1102. 
1103.     ctts_entries = av_malloc((track->entry + 1) * sizeof(*ctts_entries)); /* worst case */
1104.     ctts_entries[0].count = 1;
          ^
1105.     ctts_entries[0].duration = track->cluster[0].cts;
1106.     for (i = 1; i < track->entry; i++) {
