Skip to content
Snippets Groups Projects
Commit 49d4bd5c authored by Kevin Harwell's avatar Kevin Harwell Committed by Gerrit Code Review
Browse files

Merge "stasis_state: Make unsubscribes NULL tolerant"

parents 7f76479b 83c6ebba
No related branches found
No related tags found
No related merge requests found
......@@ -514,8 +514,11 @@ void *stasis_state_unsubscribe(struct stasis_state_subscriber *sub)
void *stasis_state_unsubscribe_and_join(struct stasis_state_subscriber *sub)
{
sub->stasis_sub = stasis_unsubscribe_and_join(sub->stasis_sub);
ao2_ref(sub, -1);
if (sub) {
sub->stasis_sub = stasis_unsubscribe_and_join(sub->stasis_sub);
ao2_ref(sub, -1);
}
return NULL;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment