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 #1866: race accessing topic replicas map #1867

Merged
merged 2 commits into from
Mar 6, 2015
Merged

fix #1866: race accessing topic replicas map #1867

merged 2 commits into from
Mar 6, 2015

Conversation

dgnorton
Copy link
Contributor

@dgnorton dgnorton commented Mar 6, 2015

No description provided.

@toddboom
Copy link
Contributor

toddboom commented Mar 6, 2015

👍

// replica returns the replica with the specified ID.
func (t *topic) replica(id uint64) *Replica {
t.mu.RLock()
defer t.mu.Unlock()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be RUnlock.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch.

@otoolep
Copy link
Contributor

otoolep commented Mar 6, 2015

Does this actually clean up the output -race. Looks like it should.

@dgnorton
Copy link
Contributor Author

dgnorton commented Mar 6, 2015

It cleans up one of the -race problems but there were several.

dgnorton added a commit that referenced this pull request Mar 6, 2015
fix #1866: race accessing topic replicas map
@dgnorton dgnorton merged commit fca0a95 into master Mar 6, 2015
@dgnorton dgnorton deleted the fix-1866 branch March 6, 2015 18:05
mark-rushakoff pushed a commit that referenced this pull request Jan 11, 2019
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.

3 participants