diff options
author | Corey Farrell <git@cfware.com> | 2018-01-07 22:38:49 -0500 |
---|---|---|
committer | Corey Farrell <git@cfware.com> | 2018-01-07 23:00:33 -0500 |
commit | 8b3083cac53df630a03e4f233701ac94c730ef95 (patch) | |
tree | 76291935cf472bef485b87a6398738c74f7a2d60 /res/res_stasis.c | |
parent | 634d30fb9e1459ca0119d8ff7a75282f2d72bcd9 (diff) |
res_stasis: Fix dial bridge unload.
If the dial bridge has been created it must be released by calling
ast_bridge_destroy, simply releasing the ao2 reference is not enough.
Also move stasis_app_control_shutdown earlier in unload to ensure the
bridge cannot be created or grabbed after the app_bridges container is
released.
Change-Id: I372302de94ca63876069e2585a049c5060e5e767
Diffstat (limited to 'res/res_stasis.c')
-rw-r--r-- | res/res_stasis.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/res/res_stasis.c b/res/res_stasis.c index 42a19bf56..1f5296d8e 100644 --- a/res/res_stasis.c +++ b/res/res_stasis.c @@ -1992,6 +1992,9 @@ static int unload_module(void) messaging_cleanup(); cleanup(); + + stasis_app_control_shutdown(); + ao2_cleanup(apps_registry); apps_registry = NULL; @@ -2007,8 +2010,6 @@ static int unload_module(void) ao2_cleanup(app_bridges_playback); app_bridges_playback = NULL; - stasis_app_control_shutdown(); - STASIS_MESSAGE_TYPE_CLEANUP(end_message_type); STASIS_MESSAGE_TYPE_CLEANUP(start_message_type); |