close file handle