]> git.ipfire.org Git - thirdparty/asterisk.git/commit
Fix crash in ConfBridge when user announcement is played for more than 2 users
authorMatthew Jordan <mjordan@digium.com>
Thu, 24 May 2012 13:32:33 +0000 (13:32 +0000)
committerMatthew Jordan <mjordan@digium.com>
Thu, 24 May 2012 13:32:33 +0000 (13:32 +0000)
commitf5b253b6119f87141f13f34fefb0345641bce032
tree393ab22976ccc0b2eb6aea90f161f56b1a32220a
parentae5a73840c8f94669486464899b7a598ab7cb582
Fix crash in ConfBridge when user announcement is played for more than 2 users

A patch introduced in r354938 made it so that ConfBridge would not attempt to
play sound files if those files did not exist.  Unfortunately, ConfBridge uses
the same underlying function, play_sound_helper, to playback both sound files
and numbers to callers.  When a number is being played back, the name of the
sound file is expected to be NULL.  This NULL value was passed into a function
that tested for the existance of a sound file and is not tolerant to NULL
file names, causing a crash.

This patch fixes the behavior, such that if a sound file does not exist we
do not attempt to play it, but we only attempt that check if the a sound file
was specified in the first place.  If a sound file was not specified, we use
the 'play number' logic in the helper function.

(closes issue ASTERISK-19899)
Reported by: Florian Gilcher
Tested by: Florian Gilcher
patches:
  asterisk-19899.diff uploaded by mjordan (license 6283)

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/10@367562 65c4cc65-6c06-0410-ace0-fbb531ad65f3
apps/app_confbridge.c