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

ffmpeg.c:3035:1: start of procedure new_video_stream()
3033. }
3034. 
3035. static void new_video_stream(AVFormatContext *oc)
      ^
3036. {
3037.     AVStream *st;

ffmpeg.c:3041:5: 
3039.     enum CodecID codec_id;
3040. 
3041.     st = av_new_stream(oc, oc->nb_streams);
          ^
3042.     if (!st) {
3043.         fprintf(stderr, "Could not alloc stream\n");

libavformat/utils.c:2366:1: start of procedure av_new_stream()
  2364. }
  2365. 
  2366. AVStream *av_new_stream(AVFormatContext *s, int id)
        ^
  2367. {
  2368.     AVStream *st;

libavformat/utils.c:2371:9: Taking true branch
  2369.     int i;
  2370. 
  2371.     if (s->nb_streams >= MAX_STREAMS)
                ^
  2372.         return NULL;
  2373. 

libavformat/utils.c:2372:9: 
  2370. 
  2371.     if (s->nb_streams >= MAX_STREAMS)
  2372.         return NULL;
                ^
  2373. 
  2374.     st = av_mallocz(sizeof(AVStream));

libavformat/utils.c:2406:1: return from a call to av_new_stream
  2404.     s->streams[s->nb_streams++] = st;
  2405.     return st;
  2406. }
        ^
  2407. 
  2408. AVProgram *av_new_program(AVFormatContext *ac, int id)

ffmpeg.c:3042:10: Taking true branch
3040. 
3041.     st = av_new_stream(oc, oc->nb_streams);
3042.     if (!st) {
               ^
3043.         fprintf(stderr, "Could not alloc stream\n");
3044.         av_exit(1);

ffmpeg.c:3043:9: 
3041.     st = av_new_stream(oc, oc->nb_streams);
3042.     if (!st) {
3043.         fprintf(stderr, "Could not alloc stream\n");
              ^
3044.         av_exit(1);
3045.     }

ffmpeg.c:3044:9: Skipping av_exit(): empty list of specs
3042.     if (!st) {
3043.         fprintf(stderr, "Could not alloc stream\n");
3044.         av_exit(1);
              ^
3045.     }
3046.     avcodec_get_context_defaults2(st->codec, CODEC_TYPE_VIDEO);

ffmpeg.c:3046:5: 
3044.         av_exit(1);
3045.     }
3046.     avcodec_get_context_defaults2(st->codec, CODEC_TYPE_VIDEO);
          ^
3047.     bitstream_filters[nb_output_files][oc->nb_streams - 1]= video_bitstream_filters;
3048.     video_bitstream_filters= NULL;
