Fix failure when filesize reading fails.