From 7a7f386886a06961b0ebf179b14f61be21c4390d Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Mon, 22 Aug 2011 12:34:46 -0500 Subject: [PATCH] FS-3337 --resolve indeed, should be ok --- .../applications/mod_conference/mod_conference.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/mod/applications/mod_conference/mod_conference.c b/src/mod/applications/mod_conference/mod_conference.c index aec526ca38..66c7a69cae 100644 --- a/src/mod/applications/mod_conference/mod_conference.c +++ b/src/mod/applications/mod_conference/mod_conference.c @@ -1498,13 +1498,15 @@ static void *SWITCH_THREAD_FUNC conference_thread_run(switch_thread_t *thread, v if (!switch_test_flag(imember, MFLAG_NOCHANNEL)) { channel = switch_core_session_get_channel(imember->session); - /* add this little bit to preserve the bridge cause code in case of an early media call that */ - /* never answers */ - if (switch_test_flag(conference, CFLAG_ANSWERED)) { - switch_channel_hangup(channel, SWITCH_CAUSE_NORMAL_CLEARING); - } else { - /* put actual cause code from outbound channel hangup here */ - switch_channel_hangup(channel, conference->bridge_hangup_cause); + if (!switch_false(switch_channel_get_variable(channel, "hangup_after_conference"))) { + /* add this little bit to preserve the bridge cause code in case of an early media call that */ + /* never answers */ + if (switch_test_flag(conference, CFLAG_ANSWERED)) { + switch_channel_hangup(channel, SWITCH_CAUSE_NORMAL_CLEARING); + } else { + /* put actual cause code from outbound channel hangup here */ + switch_channel_hangup(channel, conference->bridge_hangup_cause); + } } }