Get Alert-Info from inbound invite and set to the channel variable so that it can be passed through to the other end of the call if it is a sip call.

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3108 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Michael Jerris 2006-10-19 17:04:58 +00:00
parent c1f346b99e
commit 87aaab80d5
1 changed files with 5 additions and 1 deletions

View File

@ -3515,9 +3515,13 @@ static void sip_i_invite(nua_t *nua,
for (un=sip->sip_unknown; un; un=un->un_next) {
if (!strncasecmp(un->un_name, "Alert-Info", 10)) {
if (!switch_strlen_zero(un->un_value)) {
switch_channel_set_variable(channel, "alert_info", (char *)un->un_value);
}
// Loop thru Known Headers Here so we can do something with them
// John Doe <sip:+19018577141@209.247.16.1>;party=calling;screen=yes;privacy=off
if (!strncasecmp(un->un_name, "Remote-Party-ID", 15)) {
} else if (!strncasecmp(un->un_name, "Remote-Party-ID", 15)) {
int argc, x, screen = 1;
char *mydata, *argv[10] = { 0 };
if (!switch_strlen_zero(un->un_value)) {