"")) {
return -1;
}
- } else {
+ } else if (ast_fileexists(there_are, NULL, NULL) && ast_fileexists(other_in_party, NULL, NULL)) {
play_sound_file(conference_bridge, there_are);
play_sound_number(conference_bridge, conference_bridge->users - 1);
play_sound_file(conference_bridge, other_in_party);
{
struct ast_channel *underlying_channel;
+ /* Do not waste resources trying to play files that do not exist */
+ if (!ast_fileexists(filename, NULL, NULL)) {
+ ast_log(LOG_WARNING, "File %s does not exist in any format\n", filename);
+ return 0;
+ }
+
ast_mutex_lock(&conference_bridge->playback_lock);
if (!(conference_bridge->playback_chan)) {
if (alloc_playback_chan(conference_bridge)) {