Handle errors when opening files.