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

Preventing finalization on dead actor #198

Merged
merged 1 commit into from
Mar 3, 2014
Merged

Conversation

swistak
Copy link
Contributor

@swistak swistak commented Mar 1, 2014

When using Calluloid.shutdown there's race condition between listeners
and celluloid which in some cases leads to Listener calling #finalize on
dead actor. Added a guard that checks if actor is alive when we're
exiting from #_wait_for_changes and calls finalizer only if it's alive.

PS. I couldn't for a life figure out how to make this test pass. I hate
mocking libraries with all my heart. Feel free to fix this.

Fixes #197

When using Calluloid.shutdown there's race condition between listeners
and celluloid which in some cases leads to Listener calling #finalize on
dead actor. Added a guard that checks if actor is alive when we're
exiting from #_wait_for_changes and calls finalizer only if it's alive.

PS. I couldn't for a life figure out how to make this test pass. I hate
mocking libraries with all my heart. Feel free to fix this.

Fixes guard#197
thibaudgg added a commit that referenced this pull request Mar 3, 2014
Preventing finalization on dead actor
@thibaudgg thibaudgg merged commit 3edd00d into guard:master Mar 3, 2014
@thibaudgg
Copy link
Member

Thanks, I will commit a fix and we can continue the discussion on #197

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.

SIGINT prints warning
2 participants