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

ffmpeg.c:3099:1: start of procedure find_codec_or_die()
3097. }
3098. 
3099. static enum CodecID find_codec_or_die(const char *name, int type, int encoder, int strict)
      ^
3100. {
3101.     const char *codec_string = encoder ? "encoder" : "decoder";

ffmpeg.c:3101:32: Condition is true
3099. static enum CodecID find_codec_or_die(const char *name, int type, int encoder, int strict)
3100. {
3101.     const char *codec_string = encoder ? "encoder" : "decoder";
                                     ^
3102.     AVCodec *codec;
3103. 

ffmpeg.c:3101:5: 
3099. static enum CodecID find_codec_or_die(const char *name, int type, int encoder, int strict)
3100. {
3101.     const char *codec_string = encoder ? "encoder" : "decoder";
          ^
3102.     AVCodec *codec;
3103. 

ffmpeg.c:3104:9: Taking false branch
3102.     AVCodec *codec;
3103. 
3104.     if(!name)
              ^
3105.         return CODEC_ID_NONE;
3106.     codec = encoder ?

ffmpeg.c:3106:13: Condition is true
3104.     if(!name)
3105.         return CODEC_ID_NONE;
3106.     codec = encoder ?
                  ^
3107.         avcodec_find_encoder_by_name(name) :
3108.         avcodec_find_decoder_by_name(name);

ffmpeg.c:3106:5: 
3104.     if(!name)
3105.         return CODEC_ID_NONE;
3106.     codec = encoder ?
          ^
3107.         avcodec_find_encoder_by_name(name) :
3108.         avcodec_find_decoder_by_name(name);

ffmpeg.c:3109:9: Taking true branch
3107.         avcodec_find_encoder_by_name(name) :
3108.         avcodec_find_decoder_by_name(name);
3109.     if(!codec) {
              ^
3110.         fprintf(stderr, "Unknown %s '%s'\n", codec_string, name);
3111.         ffmpeg_exit(1);

ffmpeg.c:3110:9: 
3108.         avcodec_find_decoder_by_name(name);
3109.     if(!codec) {
3110.         fprintf(stderr, "Unknown %s '%s'\n", codec_string, name);
              ^
3111.         ffmpeg_exit(1);
3112.     }

ffmpeg.c:3111:9: Skipping ffmpeg_exit(): empty list of specs
3109.     if(!codec) {
3110.         fprintf(stderr, "Unknown %s '%s'\n", codec_string, name);
3111.         ffmpeg_exit(1);
              ^
3112.     }
3113.     if(codec->type != type) {

ffmpeg.c:3113:8: 
3111.         ffmpeg_exit(1);
3112.     }
3113.     if(codec->type != type) {
             ^
3114.         fprintf(stderr, "Invalid %s type '%s'\n", codec_string, name);
3115.         ffmpeg_exit(1);
