avconv.c:1298: error: Null Dereference
  pointer `vstats_file` last assigned on line 1288 could be null and is dereferenced by call to `fprintf()` at line 1298, column 9.

avconv.c:1279:1: start of procedure do_video_stats()
1277. }
1278. 
1279. static void do_video_stats(AVFormatContext *os, OutputStream *ost,
      ^
1280.                            int frame_size)
1281. {

avconv.c:1287:10: Taking true branch
1285. 
1286.     /* this is executed just the first time do_video_stats is called */
1287.     if (!vstats_file) {
               ^
1288.         vstats_file = fopen(vstats_filename, "w");
1289.         if (!vstats_file) {

avconv.c:1288:9: 
1286.     /* this is executed just the first time do_video_stats is called */
1287.     if (!vstats_file) {
1288.         vstats_file = fopen(vstats_filename, "w");
              ^
1289.         if (!vstats_file) {
1290.             perror("fopen");

avconv.c:1289:14: Taking true branch
1287.     if (!vstats_file) {
1288.         vstats_file = fopen(vstats_filename, "w");
1289.         if (!vstats_file) {
                   ^
1290.             perror("fopen");
1291.             exit_program(1);

avconv.c:1290:13: 
1288.         vstats_file = fopen(vstats_filename, "w");
1289.         if (!vstats_file) {
1290.             perror("fopen");
                  ^
1291.             exit_program(1);
1292.         }

avconv.c:1291:13: Skipping exit_program(): empty list of specs
1289.         if (!vstats_file) {
1290.             perror("fopen");
1291.             exit_program(1);
                  ^
1292.         }
1293.     }

avconv.c:1295:5: 
1293.     }
1294. 
1295.     enc = ost->st->codec;
          ^
1296.     if (enc->codec_type == AVMEDIA_TYPE_VIDEO) {
1297.         frame_number = ost->frame_number;

avconv.c:1296:9: Taking true branch
1294. 
1295.     enc = ost->st->codec;
1296.     if (enc->codec_type == AVMEDIA_TYPE_VIDEO) {
              ^
1297.         frame_number = ost->frame_number;
1298.         fprintf(vstats_file, "frame= %5d q= %2.1f ", frame_number, enc->coded_frame->quality/(float)FF_QP2LAMBDA);

avconv.c:1297:9: 
1295.     enc = ost->st->codec;
1296.     if (enc->codec_type == AVMEDIA_TYPE_VIDEO) {
1297.         frame_number = ost->frame_number;
              ^
1298.         fprintf(vstats_file, "frame= %5d q= %2.1f ", frame_number, enc->coded_frame->quality/(float)FF_QP2LAMBDA);
1299.         if (enc->flags&CODEC_FLAG_PSNR)

avconv.c:1298:9: 
1296.     if (enc->codec_type == AVMEDIA_TYPE_VIDEO) {
1297.         frame_number = ost->frame_number;
1298.         fprintf(vstats_file, "frame= %5d q= %2.1f ", frame_number, enc->coded_frame->quality/(float)FF_QP2LAMBDA);
              ^
1299.         if (enc->flags&CODEC_FLAG_PSNR)
1300.             fprintf(vstats_file, "PSNR= %6.2f ", psnr(enc->coded_frame->error[0]/(enc->width*enc->height*255.0*255.0)));
