[asterisk-commits] rmudgett: branch 11 r410490 - /branches/11/apps/confbridge/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Mar 12 13:35:24 CDT 2014


Author: rmudgett
Date: Wed Mar 12 13:35:14 2014
New Revision: 410490

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=410490
Log:
app_confbridge: Make explicitly stop MOH if a user is kicked or hangs up while MOH is playing.

When MOH is playing to a user in a conference and the user is kicked or
hangs up from the conference then the AMI MusicOnHoldStop events didn't
happen.  (Asterisk v11 AMI event: MusicOnHold, state:Stop)

(closes issue ASTERISK-23311)
Reported by: Benjamin Keith Ford

Review: https://reviewboard.asterisk.org/r/3306/

Modified:
    branches/11/apps/confbridge/conf_state.c
    branches/11/apps/confbridge/conf_state_inactive.c
    branches/11/apps/confbridge/conf_state_single.c
    branches/11/apps/confbridge/conf_state_single_marked.c

Modified: branches/11/apps/confbridge/conf_state.c
URL: http://svnview.digium.com/svn/asterisk/branches/11/apps/confbridge/conf_state.c?view=diff&rev=410490&r1=410489&r2=410490
==============================================================================
--- branches/11/apps/confbridge/conf_state.c (original)
+++ branches/11/apps/confbridge/conf_state.c Wed Mar 12 13:35:14 2014
@@ -74,6 +74,9 @@
 void conf_default_leave_waitmarked(struct conference_bridge_user *cbu)
 {
 	conf_remove_user_waiting(cbu->conference_bridge, cbu);
+	if (cbu->playing_moh) {
+		conf_moh_stop(cbu);
+	}
 }
 
 void conf_change_state(struct conference_bridge_user *cbu, struct conference_state *newstate)

Modified: branches/11/apps/confbridge/conf_state_inactive.c
URL: http://svnview.digium.com/svn/asterisk/branches/11/apps/confbridge/conf_state_inactive.c?view=diff&rev=410490&r1=410489&r2=410490
==============================================================================
--- branches/11/apps/confbridge/conf_state_inactive.c (original)
+++ branches/11/apps/confbridge/conf_state_inactive.c Wed Mar 12 13:35:14 2014
@@ -68,7 +68,7 @@
 
 static void leave_waitmarked(struct conference_bridge_user *cbu)
 {
-	conf_remove_user_waiting(cbu->conference_bridge, cbu);
+	conf_default_leave_waitmarked(cbu);
 	if (cbu->conference_bridge->waitingusers == 0) {
 		conf_change_state(cbu, CONF_STATE_EMPTY);
 	}

Modified: branches/11/apps/confbridge/conf_state_single.c
URL: http://svnview.digium.com/svn/asterisk/branches/11/apps/confbridge/conf_state_single.c?view=diff&rev=410490&r1=410489&r2=410490
==============================================================================
--- branches/11/apps/confbridge/conf_state_single.c (original)
+++ branches/11/apps/confbridge/conf_state_single.c Wed Mar 12 13:35:14 2014
@@ -72,6 +72,9 @@
 static void leave_unmarked(struct conference_bridge_user *cbu)
 {
 	conf_remove_user_active(cbu->conference_bridge, cbu);
+	if (cbu->playing_moh) {
+		conf_moh_stop(cbu);
+	}
 
 	if (cbu->conference_bridge->waitingusers) {
 		conf_change_state(cbu, CONF_STATE_INACTIVE);

Modified: branches/11/apps/confbridge/conf_state_single_marked.c
URL: http://svnview.digium.com/svn/asterisk/branches/11/apps/confbridge/conf_state_single_marked.c?view=diff&rev=410490&r1=410489&r2=410490
==============================================================================
--- branches/11/apps/confbridge/conf_state_single_marked.c (original)
+++ branches/11/apps/confbridge/conf_state_single_marked.c Wed Mar 12 13:35:14 2014
@@ -71,6 +71,9 @@
 static void leave_marked(struct conference_bridge_user *cbu)
 {
 	conf_remove_user_marked(cbu->conference_bridge, cbu);
+	if (cbu->playing_moh) {
+		conf_moh_stop(cbu);
+	}
 
 	conf_change_state(cbu, CONF_STATE_EMPTY);
 }




More information about the asterisk-commits mailing list