Trying to print error number when opening file