[asterisk-commits] stasis bridge.c: Fix off-nominal stasis control ref leak. (asterisk[master])

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Jan 25 13:32:40 CST 2017


Anonymous Coward #1000019 has submitted this change and it was merged. ( https://gerrit.asterisk.org/4791 )

Change subject: stasis_bridge.c: Fix off-nominal stasis control ref leak.
......................................................................


stasis_bridge.c: Fix off-nominal stasis control ref leak.

Change-Id: Ib17218343a6596832060180e19386da9df150ac8
---
M res/stasis/stasis_bridge.c
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  George Joseph: Looks good to me, but someone else must approve
  Anonymous Coward #1000019: Verified
  Matthew Fredrickson: Looks good to me, approved



diff --git a/res/stasis/stasis_bridge.c b/res/stasis/stasis_bridge.c
index 95e549a..104d319 100644
--- a/res/stasis/stasis_bridge.c
+++ b/res/stasis/stasis_bridge.c
@@ -215,6 +215,7 @@
 		 */
 		return -1;
 	}
+	ao2_cleanup(control);
 
 	/*
 	 * If going into a holding bridge, default the role to participant, if
@@ -234,7 +235,6 @@
 		}
 	}
 
-	ao2_cleanup(control);
 	if (self->allowed_capabilities & STASIS_BRIDGE_MIXING_CAPABILITIES) {
 		ast_bridge_channel_update_linkedids(bridge_channel, swap);
 		if (ast_test_flag(&self->feature_flags, AST_BRIDGE_FLAG_SMART)) {

-- 
To view, visit https://gerrit.asterisk.org/4791
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib17218343a6596832060180e19386da9df150ac8
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Matthew Fredrickson <creslin at digium.com>



More information about the asterisk-commits mailing list