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

ffmpeg.c:2990:1: start of procedure new_video_stream()
2988. }
2989. 
2990. static void new_video_stream(AVFormatContext *oc)
      ^
2991. {
2992.     AVStream *st;

ffmpeg.c:2996:5: 
2994.     int codec_id;
2995. 
2996.     st = av_new_stream(oc, oc->nb_streams);
          ^
2997.     if (!st) {
2998.         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:2997:10: Taking true branch
2995. 
2996.     st = av_new_stream(oc, oc->nb_streams);
2997.     if (!st) {
               ^
2998.         fprintf(stderr, "Could not alloc stream\n");
2999.         av_exit(1);

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

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

ffmpeg.c:3001:5: 
2999.         av_exit(1);
3000.     }
3001.     avcodec_get_context_defaults2(st->codec, CODEC_TYPE_VIDEO);
          ^
3002.     bitstream_filters[nb_output_files][oc->nb_streams - 1]= video_bitstream_filters;
3003.     video_bitstream_filters= NULL;
