share and share alike, only nothing is alike in sip =/

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16194 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale
2010-01-07 06:09:35 +00:00
parent f5d74122bd
commit 478f165d25
5 changed files with 335 additions and 232 deletions

View File

@@ -512,6 +512,7 @@ SWITCH_DECLARE(void) switch_channel_presence(switch_channel_t *channel, const ch
call_info_state = "alerting";
}
}
switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "presence-call-info-state", call_info_state);
switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "presence-call-info", call_info);
}
@@ -1920,6 +1921,10 @@ SWITCH_DECLARE(switch_channel_state_t) switch_channel_perform_hangup(switch_chan
switch_channel_state_t last_state;
switch_event_t *event;
if (hangup_cause == SWITCH_CAUSE_LOSE_RACE) {
switch_channel_set_variable(channel, "presence_call_info", NULL);
}
switch_mutex_lock(channel->state_mutex);
last_state = channel->state;
channel->state = CS_HANGUP;