func (file *File) Close() os.Error { if file == nil { return os.EINVAL } e := syscall.Close(file.fd) file.fd = -1 // so it can't be closed again if e != 0 { return os.Errno(e) } return nil } //go/4351