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 a potential deadlock that could occur when encoding for REST. #429

Merged
merged 1 commit into from
Oct 16, 2015

Conversation

richardjrossiii
Copy link
Contributor

We didn't actually need to hold the lock here, and if we did, another thread could have acquired these locks in another order, causing a deadlock.

Should help to fix #398, #11, and a few others.


return [self RESTDictionaryWithObjectEncoder:objectEncoder
operationSetUUIDs:operationSetUUIDs
state:state
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: Re-indent.

@nlutsenko
Copy link
Contributor

Fix tests, re-indent and ship!

We didn't actually need to hold the lock here, and if we did, another thread could have acquired these locks in another order, causing a deadlock.

Should help to fix #398, #11, and a few others.
@richardjrossiii richardjrossiii force-pushed the richardross.restdictionary.deadlock branch from d2f1ec5 to 6a9dcc2 Compare October 16, 2015 22:53
richardjrossiii added a commit that referenced this pull request Oct 16, 2015
….deadlock

Fix a potential deadlock that could occur when encoding for REST.
@richardjrossiii richardjrossiii merged commit 9078676 into master Oct 16, 2015
@richardjrossiii richardjrossiii deleted the richardross.restdictionary.deadlock branch October 16, 2015 23:44
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.

Deadlock
3 participants