ffmpeg.c:3635: error: Null Dereference
  pointer `st` last assigned on line 3629 could be null and is dereferenced at line 3635, column 16.

ffmpeg.c:3623:1: start of procedure new_data_stream()
3621. }
3622. 
3623. static void new_data_stream(AVFormatContext *oc, int file_idx)
      ^
3624. {
3625.     AVStream *st;

ffmpeg.c:3626:5: 
3624. {
3625.     AVStream *st;
3626.     AVCodec *codec=NULL;
          ^
3627.     AVCodecContext *data_enc;
3628. 

ffmpeg.c:3629:28: Condition is true
3627.     AVCodecContext *data_enc;
3628. 
3629.     st = av_new_stream(oc, oc->nb_streams < nb_streamid_map ? streamid_map[oc->nb_streams] : 0);
                                 ^
3630.     if (!st) {
3631.         fprintf(stderr, "Could not alloc stream\n");

ffmpeg.c:3629:5: 
3627.     AVCodecContext *data_enc;
3628. 
3629.     st = av_new_stream(oc, oc->nb_streams < nb_streamid_map ? streamid_map[oc->nb_streams] : 0);
          ^
3630.     if (!st) {
3631.         fprintf(stderr, "Could not alloc stream\n");

libavformat/utils.c:2582:1: start of procedure av_new_stream()
  2580. }
  2581. 
  2582. AVStream *av_new_stream(AVFormatContext *s, int id)
        ^
  2583. {
  2584.     AVStream *st;

libavformat/utils.c:2588:9: Taking true branch
  2586.     AVStream **streams;
  2587. 
  2588.     if (s->nb_streams >= INT_MAX/sizeof(*streams))
                ^
  2589.         return NULL;
  2590.     streams = av_realloc(s->streams, (s->nb_streams + 1) * sizeof(*streams));

libavformat/utils.c:2589:9: 
  2587. 
  2588.     if (s->nb_streams >= INT_MAX/sizeof(*streams))
  2589.         return NULL;
                ^
  2590.     streams = av_realloc(s->streams, (s->nb_streams + 1) * sizeof(*streams));
  2591.     if (!streams)

libavformat/utils.c:2631:1: return from a call to av_new_stream
  2629.     s->streams[s->nb_streams++] = st;
  2630.     return st;
  2631. }
        ^
  2632. 
  2633. AVProgram *av_new_program(AVFormatContext *ac, int id)

ffmpeg.c:3630:10: Taking true branch
3628. 
3629.     st = av_new_stream(oc, oc->nb_streams < nb_streamid_map ? streamid_map[oc->nb_streams] : 0);
3630.     if (!st) {
               ^
3631.         fprintf(stderr, "Could not alloc stream\n");
3632.         ffmpeg_exit(1);

ffmpeg.c:3631:9: 
3629.     st = av_new_stream(oc, oc->nb_streams < nb_streamid_map ? streamid_map[oc->nb_streams] : 0);
3630.     if (!st) {
3631.         fprintf(stderr, "Could not alloc stream\n");
              ^
3632.         ffmpeg_exit(1);
3633.     }

ffmpeg.c:3632:9: Skipping ffmpeg_exit(): empty list of specs
3630.     if (!st) {
3631.         fprintf(stderr, "Could not alloc stream\n");
3632.         ffmpeg_exit(1);
              ^
3633.     }
3634.     new_output_stream(oc, file_idx);

ffmpeg.c:3634:5: Skipping new_output_stream(): empty list of specs
3632.         ffmpeg_exit(1);
3633.     }
3634.     new_output_stream(oc, file_idx);
          ^
3635.     data_enc = st->codec;
3636.     output_codecs = grow_array(output_codecs, sizeof(*output_codecs), &nb_output_codecs, nb_output_codecs + 1);

ffmpeg.c:3635:5: 
3633.     }
3634.     new_output_stream(oc, file_idx);
3635.     data_enc = st->codec;
          ^
3636.     output_codecs = grow_array(output_codecs, sizeof(*output_codecs), &nb_output_codecs, nb_output_codecs + 1);
3637.     if (!data_stream_copy) {
