ffmpeg.c:3128: error: Null Dereference
  pointer `codec` last assigned on line 3121 could be null and is dereferenced at line 3128, column 8.

ffmpeg.c:3114:1: start of procedure find_codec_or_die()
3112. }
3113. 
3114. static enum CodecID find_codec_or_die(const char *name, int type, int encoder, int strict)
      ^
3115. {
3116.     const char *codec_string = encoder ? "encoder" : "decoder";

ffmpeg.c:3116:32: Condition is true
3114. static enum CodecID find_codec_or_die(const char *name, int type, int encoder, int strict)
3115. {
3116.     const char *codec_string = encoder ? "encoder" : "decoder";
                                     ^
3117.     AVCodec *codec;
3118. 

ffmpeg.c:3116:5: 
3114. static enum CodecID find_codec_or_die(const char *name, int type, int encoder, int strict)
3115. {
3116.     const char *codec_string = encoder ? "encoder" : "decoder";
          ^
3117.     AVCodec *codec;
3118. 

ffmpeg.c:3119:9: Taking false branch
3117.     AVCodec *codec;
3118. 
3119.     if(!name)
              ^
3120.         return CODEC_ID_NONE;
3121.     codec = encoder ?

ffmpeg.c:3121:13: Condition is true
3119.     if(!name)
3120.         return CODEC_ID_NONE;
3121.     codec = encoder ?
                  ^
3122.         avcodec_find_encoder_by_name(name) :
3123.         avcodec_find_decoder_by_name(name);

ffmpeg.c:3121:5: 
3119.     if(!name)
3120.         return CODEC_ID_NONE;
3121.     codec = encoder ?
          ^
3122.         avcodec_find_encoder_by_name(name) :
3123.         avcodec_find_decoder_by_name(name);

ffmpeg.c:3124:9: Taking true branch
3122.         avcodec_find_encoder_by_name(name) :
3123.         avcodec_find_decoder_by_name(name);
3124.     if(!codec) {
              ^
3125.         fprintf(stderr, "Unknown %s '%s'\n", codec_string, name);
3126.         ffmpeg_exit(1);

ffmpeg.c:3125:9: 
3123.         avcodec_find_decoder_by_name(name);
3124.     if(!codec) {
3125.         fprintf(stderr, "Unknown %s '%s'\n", codec_string, name);
              ^
3126.         ffmpeg_exit(1);
3127.     }

ffmpeg.c:3126:9: Skipping ffmpeg_exit(): empty list of specs
3124.     if(!codec) {
3125.         fprintf(stderr, "Unknown %s '%s'\n", codec_string, name);
3126.         ffmpeg_exit(1);
              ^
3127.     }
3128.     if(codec->type != type) {

ffmpeg.c:3128:8: 
3126.         ffmpeg_exit(1);
3127.     }
3128.     if(codec->type != type) {
             ^
3129.         fprintf(stderr, "Invalid %s type '%s'\n", codec_string, name);
3130.         ffmpeg_exit(1);
