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

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

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

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

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

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

ffmpeg.c:3103:5: 
3101.     if(!name)
3102.         return CODEC_ID_NONE;
3103.     codec = encoder ?
          ^
3104.         avcodec_find_encoder_by_name(name) :
3105.         avcodec_find_decoder_by_name(name);

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

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

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

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