FS-3487 gonna guess, try this...

This commit is contained in:
Anthony Minessale 2011-08-04 16:34:01 -05:00
parent 308f44af2e
commit 714195b8f2
1 changed files with 9 additions and 8 deletions

View File

@ -952,9 +952,8 @@ static void our_sofia_event_callback(nua_event_t event,
}
}
case nua_r_ack:
if (channel) {
if (channel)
switch_channel_set_flag(channel, CF_MEDIA_ACK);
}
break;
case nua_r_shutdown:
if (status >= 200) {
@ -4969,12 +4968,6 @@ static void sofia_handle_sip_r_invite(switch_core_session_t *session, int status
sofia_clear_flag(tech_pvt, TFLAG_RECOVERING);
}
if ((status == 180 || status == 183) && switch_channel_direction(channel) == SWITCH_CALL_DIRECTION_OUTBOUND) {
const char *val;
if ((val = switch_channel_get_variable(channel, "sip_auto_answer")) && switch_true(val)) {
nua_notify(nh, NUTAG_NEWSUB(1), NUTAG_SUBSTATE(nua_substate_active), SIPTAG_EVENT_STR("talk"), TAG_END());
}
}
}
end:
@ -5165,6 +5158,14 @@ static void sofia_handle_sip_i_state(switch_core_session_t *session, int status,
status = 183;
}
if (channel && (status == 180 || status == 183) && switch_channel_direction(channel) == SWITCH_CALL_DIRECTION_OUTBOUND) {
const char *val;
if ((val = switch_channel_get_variable(channel, "sip_auto_answer")) && switch_true(val)) {
nua_notify(nh, NUTAG_NEWSUB(1), NUTAG_SUBSTATE(nua_substate_active), SIPTAG_EVENT_STR("talk"), TAG_END());
}
}
state_process: