[asterisk-bugs] [JIRA] (ASTERISK-21903) Add return code to AGI for some errors

Ariel Wainer (JIRA) noreply at issues.asterisk.org
Wed Jun 12 09:33:03 CDT 2013


Ariel Wainer created ASTERISK-21903:
---------------------------------------

             Summary: Add return code to AGI for some errors
                 Key: ASTERISK-21903
                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-21903
             Project: Asterisk
          Issue Type: Improvement
      Security Level: None
          Components: . I did not set the category correctly.
    Affects Versions: 11.4.0
            Reporter: Ariel Wainer
            Severity: Minor


When playing audio files from an AGI script, if for some reason Asterisk fails to play the fail, currently there is no way to tell from the script.
To illustrate, this is the debug transcript from an AGI script trying to play an non-existent file:

{quote}
<SIP/192.168.200.3-0000007d>AGI Rx << GET OPTION "content/00/3000" ""*0#"" "1000"
[Jun 12 10:48:12] WARNING[24554]: file.c:663 ast_openstream_full: File content/00/3000 does not exist in any format
<SIP/192.168.200.3-0000007d>AGI Tx >> 200 result=0 endpos=0
[Jun 12 10:48:12] WARNING[24554]: res_agi.c:2003 handle_getoption: Unable to open content/00/3000
{quote}

Since Asterisk didn't succeed to execute the command, the return code 200 doesn't make sense. I think it should be 404 if the file does not exists or 503 if it doesn't the right permission, to continue with the HTTP analogy.
Even a basic code 500 for anything else than success would be useful.

Best regards,
Ari

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.asterisk.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira



More information about the asterisk-bugs mailing list