add more explicit handling of file errors on open