Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix owner reference not normally exported from VirtualFileSystem.selectUser #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Xanonymous-GitHub
Copy link

Since golang actually copy the value before entering a for... loop with range, we can not use the reference from the range as the final exported reference, because it is Not the origin reference.

However, we can use array index to know which position is our target, so we save that index, and finally return the origin reference with that index.

Please refer to this issue for more detail: golang/go#20733

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant