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

ffmpeg.c:3563:1: start of procedure new_subtitle_stream()
3561. }
3562. 
3563. static void new_subtitle_stream(AVFormatContext *oc)
      ^
3564. {
3565.     AVStream *st;

ffmpeg.c:3568:5: 
3566.     AVCodecContext *subtitle_enc;
3567. 
3568.     st = av_new_stream(oc, streamid_map[oc->nb_streams]);
          ^
3569.     if (!st) {
3570.         fprintf(stderr, "Could not alloc stream\n");

libavformat/utils.c:2500:1: start of procedure av_new_stream()
  2498. }
  2499. 
  2500. AVStream *av_new_stream(AVFormatContext *s, int id)
        ^
  2501. {
  2502.     AVStream *st;

libavformat/utils.c:2505:9: Taking true branch
  2503.     int i;
  2504. 
  2505.     if (s->nb_streams >= MAX_STREAMS){
                ^
  2506.         av_log(s, AV_LOG_ERROR, "Too many streams\n");
  2507.         return NULL;

libavformat/utils.c:2506:9: Skipping av_log(): empty list of specs
  2504. 
  2505.     if (s->nb_streams >= MAX_STREAMS){
  2506.         av_log(s, AV_LOG_ERROR, "Too many streams\n");
                ^
  2507.         return NULL;
  2508.     }

libavformat/utils.c:2507:9: 
  2505.     if (s->nb_streams >= MAX_STREAMS){
  2506.         av_log(s, AV_LOG_ERROR, "Too many streams\n");
  2507.         return NULL;
                ^
  2508.     }
  2509. 

libavformat/utils.c:2542:1: return from a call to av_new_stream
  2540.     s->streams[s->nb_streams++] = st;
  2541.     return st;
  2542. }
        ^
  2543. 
  2544. AVProgram *av_new_program(AVFormatContext *ac, int id)

ffmpeg.c:3569:10: Taking true branch
3567. 
3568.     st = av_new_stream(oc, streamid_map[oc->nb_streams]);
3569.     if (!st) {
               ^
3570.         fprintf(stderr, "Could not alloc stream\n");
3571.         ffmpeg_exit(1);

ffmpeg.c:3570:9: 
3568.     st = av_new_stream(oc, streamid_map[oc->nb_streams]);
3569.     if (!st) {
3570.         fprintf(stderr, "Could not alloc stream\n");
              ^
3571.         ffmpeg_exit(1);
3572.     }

ffmpeg.c:3571:9: Skipping ffmpeg_exit(): empty list of specs
3569.     if (!st) {
3570.         fprintf(stderr, "Could not alloc stream\n");
3571.         ffmpeg_exit(1);
              ^
3572.     }
3573.     avcodec_get_context_defaults2(st->codec, AVMEDIA_TYPE_SUBTITLE);

ffmpeg.c:3573:5: 
3571.         ffmpeg_exit(1);
3572.     }
3573.     avcodec_get_context_defaults2(st->codec, AVMEDIA_TYPE_SUBTITLE);
          ^
3574. 
3575.     bitstream_filters[nb_output_files][oc->nb_streams - 1]= subtitle_bitstream_filters;
