]> git.ipfire.org Git - thirdparty/asterisk.git/commit
audiohooks: Reevaluate the bridge technology when an audiohook is added or removed.
authorRichard Mudgett <rmudgett@digium.com>
Fri, 3 Oct 2014 19:36:09 +0000 (19:36 +0000)
committerRichard Mudgett <rmudgett@digium.com>
Fri, 3 Oct 2014 19:36:09 +0000 (19:36 +0000)
commit3691b202704deb9fbe3e04cc767571871549b905
tree888ac664e63c3607a08f920c4d14cd74e4428346
parent4869e033fb45a1edbe52414f7d0591ffbf646d25
audiohooks: Reevaluate the bridge technology when an audiohook is added or removed.

Adding a mixmonitor to a channel causes the bridge to change technologies
from native to simple_bridge so the call can be recorded.  However, when
the mixmonitor is stopped the bridge does not switch back to the native
technology.

* Added unbridge requests to reevaluate the bridge when a channel
audiohook is removed.

* Moved the unbridge request into ast_audiohook_attach() ensure that the
bridge reevaluates whenever an audiohook is attached.  This simplified the
mixmonitor and chan_spy start code as well.

* Added defensive code to stop_mixmonitor_full() in case additional
arguments are ever added to the StopMixMonitor application.

* Made ast_framehook_detach() not do an unbridge request if the framehook
does not exist.

* Made ast_framehook_list_fixup() do an unbridge request if there are any
framehooks.  Also simplified the loop.

ASTERISK-24195 #close
Reported by: Jonathan Rose

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

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/12@424506 65c4cc65-6c06-0410-ace0-fbb531ad65f3
apps/app_chanspy.c
apps/app_mixmonitor.c
main/audiohook.c
main/framehook.c