ffmpeg.c:3005: error: Null Dereference
  pointer `st` last assigned on line 3000 could be null and is dereferenced at line 3005, column 35.

ffmpeg.c:2994:1: start of procedure new_video_stream()
2992. }
2993. 
2994. static void new_video_stream(AVFormatContext *oc)
      ^
2995. {
2996.     AVStream *st;

ffmpeg.c:3000:5: 
2998.     int codec_id;
2999. 
3000.     st = av_new_stream(oc, oc->nb_streams);
          ^
3001.     if (!st) {
3002.         fprintf(stderr, "Could not alloc stream\n");

libavformat/utils.c:2305:1: start of procedure av_new_stream()
  2303. }
  2304. 
  2305. AVStream *av_new_stream(AVFormatContext *s, int id)
        ^
  2306. {
  2307.     AVStream *st;

libavformat/utils.c:2310:9: Taking true branch
  2308.     int i;
  2309. 
  2310.     if (s->nb_streams >= MAX_STREAMS)
                ^
  2311.         return NULL;
  2312. 

libavformat/utils.c:2311:9: 
  2309. 
  2310.     if (s->nb_streams >= MAX_STREAMS)
  2311.         return NULL;
                ^
  2312. 
  2313.     st = av_mallocz(sizeof(AVStream));

libavformat/utils.c:2343:1: return from a call to av_new_stream
  2341.     s->streams[s->nb_streams++] = st;
  2342.     return st;
  2343. }
        ^
  2344. 
  2345. AVProgram *av_new_program(AVFormatContext *ac, int id)

ffmpeg.c:3001:10: Taking true branch
2999. 
3000.     st = av_new_stream(oc, oc->nb_streams);
3001.     if (!st) {
               ^
3002.         fprintf(stderr, "Could not alloc stream\n");
3003.         av_exit(1);

ffmpeg.c:3002:9: 
3000.     st = av_new_stream(oc, oc->nb_streams);
3001.     if (!st) {
3002.         fprintf(stderr, "Could not alloc stream\n");
              ^
3003.         av_exit(1);
3004.     }

ffmpeg.c:3003:9: Skipping av_exit(): empty list of specs
3001.     if (!st) {
3002.         fprintf(stderr, "Could not alloc stream\n");
3003.         av_exit(1);
              ^
3004.     }
3005.     avcodec_get_context_defaults2(st->codec, CODEC_TYPE_VIDEO);

ffmpeg.c:3005:5: 
3003.         av_exit(1);
3004.     }
3005.     avcodec_get_context_defaults2(st->codec, CODEC_TYPE_VIDEO);
          ^
3006.     bitstream_filters[nb_output_files][oc->nb_streams - 1]= video_bitstream_filters;
3007.     video_bitstream_filters= NULL;
