confbridge: Fix MOH on simultaneous user entry to a new conference.
authorRichard Mudgett <rmudgett@digium.com>
Thu, 13 Dec 2012 21:28:15 +0000 (21:28 +0000)
committerRichard Mudgett <rmudgett@digium.com>
Thu, 13 Dec 2012 21:28:15 +0000 (21:28 +0000)
commitb17f7cab952f61ce35bc62d227103ca6e8a94980
tree73841c6f56ea5fac5c3f519238ef1d6c7167218d
parent5cf8a1f2e502f4b50bc0f2a8f955798ba3e73275
confbridge: Fix MOH on simultaneous user entry to a new conference.

When two users entered a new conference simultaneously, one of the callers
hears MOH.  This happened if two unmarked users entered simultaneously and
also if a waitmarked and a marked user entered simultaneously.

* Created a confbridge internal MOH API to eliminate the inlined MOH
handling code.  Note that the conference mixing bridge needs to be locked
when actually starting/stopping MOH because there is a small window
between the conference join unsuspend MOH and actually joining the mixing
bridge.

* Created the concept of suspended MOH so it can be interrupted while
conference join announcements to the user and DTMF features can operate.

* Suspend any MOH until the user is about to actually join the mixing
bridge of the conference.  This way any pre-join file playback does not
need to worry about MOH.

* Made post-join actions only play deferred entry announcement files.
Changing the user/conference state during that time is not protected or
controlled by the state machine.

(closes issue ASTERISK-20606)
Reported by: Eugenia Belova
Tested by: rmudgett

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

Merged revisions 377992 from http://svn.asterisk.org/svn/asterisk/branches/10
........

Merged revisions 377993 from http://svn.asterisk.org/svn/asterisk/branches/11

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@378002 65c4cc65-6c06-0410-ace0-fbb531ad65f3
apps/app_confbridge.c
apps/confbridge/conf_state.c
apps/confbridge/conf_state_multi_marked.c
apps/confbridge/include/confbridge.h
include/asterisk/bridging.h