Merge pull request #862 in FS/freeswitch from ~LAZEDO/freeswitch:feature/FS-9188 to master

* commit '08199210c1f548a1aa9a302c32eb89fabbf90301':
  [mod_sofia] [FS-9188] added channel var to suppress auto-answer notify
This commit is contained in:
Mike Jerris 2016-05-26 16:28:07 -05:00
commit a838c29e41
1 changed files with 3 additions and 2 deletions

View File

@ -6919,8 +6919,9 @@ static void sofia_handle_sip_i_state(switch_core_session_t *session, int status,
if (channel && (status == 180 || status == 183) && switch_channel_direction(channel) == SWITCH_CALL_DIRECTION_OUTBOUND) {
const char *full_to = NULL;
const char *val;
if ((val = switch_channel_get_variable(channel, "sip_auto_answer")) && switch_true(val)) {
const char *var;
if ((var = switch_channel_get_variable(channel, "sip_auto_answer")) && switch_true(var) &&
!((var = switch_channel_get_variable(channel, "sip_auto_answer_suppress_notify")) && switch_true(var))) {
full_to = switch_str_nil(switch_channel_get_variable(channel, "sip_full_to"));
nua_notify(nh,