ffmpeg.c:3789: error: Null Dereference
  pointer `today` last assigned on line 3787 could be null and is dereferenced at line 3789, column 69.

ffmpeg.c:3783:1: start of procedure opt_vstats()
3781. }
3782. 
3783. static void opt_vstats (void)
      ^
3784. {
3785.     char filename[40];

ffmpeg.c:3786:5: 
3784. {
3785.     char filename[40];
3786.     time_t today2 = time(NULL);
          ^
3787.     struct tm *today = localtime(&today2);
3788. 

ffmpeg.c:3787:5: 
3785.     char filename[40];
3786.     time_t today2 = time(NULL);
3787.     struct tm *today = localtime(&today2);
          ^
3788. 
3789.     snprintf(filename, sizeof(filename), "vstats_%02d%02d%02d.log", today->tm_hour, today->tm_min,

ffmpeg.c:3789:5: 
3787.     struct tm *today = localtime(&today2);
3788. 
3789.     snprintf(filename, sizeof(filename), "vstats_%02d%02d%02d.log", today->tm_hour, today->tm_min,
          ^
3790.              today->tm_sec);
3791.     opt_vstats_file(filename);
