Fix crash on unreadable files.