[Home]

Summary:ASTERISK-15029: [patch] ExternalIVR trapping non-existent files does not work
Reporter:David Ruggles (thedavidfactor)Labels:
Date Opened:2009-10-23 16:24:30Date Closed:2009-11-21 14:39:06.000-0600
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Applications/app_externalivr
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) app_externalivr2.patch
Description:The documentation for ExternalIVR states:

The 'S' command checks to see if there is a playable audio file with the specified name, and if so, clear's the generator's playlist and places the file onto the list. Note that the playability check does not take into account transcoding requirements, so it is possible for the file to not be played even though it was found. If the file cannot be found, a 'Z' event (see above) will be sent to the child.

And:

The 'A' command checks to see if there is a playable audio file with
the specified name, and if so, adds it to the generator's
playlist. The same playability and exception rules apply as for the
'S' command.

This doesn't work. Nothing is returned if the files doesn't exist. I tracked that down to conditional test that was not valid:

727: if (ast_fileexists(&input[2], NULL, u->chan->language) == -1) {

However fixing that lead to a second problem, ExternalIVR would then attempt to play the file "exception" so I modified it further to not attempt to play the file if the conditional test on line 727 failed. In addition I added the missing file information to the data of the returned eivr_event because I felt that it was in the spirit of the other return values related to playing files. (F & D specifically)
Comments:By: David Ruggles (thedavidfactor) 2009-11-21 14:39:06.000-0600

Implemented in trunk (Revision 230584)