fixed error when trying to close file not opened