-- Asterisk will now also look in the regular context for the fax extension while
executing a macro. Previously, for this to work, the fax extension would have
to be included in the macro definition.
+ -- On some systems, ALERTING will be sent after PROCEEDING, so code has been
+ added to account for this case.
-- chan_sip
-- We no longer send a "to" tag on "100 Trying" messages, as it is inappropriate
to do so.
int logicalspan;
int alreadyhungup;
int proceeding;
+ int alerting;
int setup_ack; /* wheter we received SETUP_ACKNOWLEDGE or not */
#endif
#ifdef ZAPATA_R2
p->onhooktime = time(NULL);
#ifdef ZAPATA_PRI
p->proceeding = 0;
+ p->alerting = 0;
p->setup_ack = 0;
#endif
if (p->dsp) {
if (flags & (AST_BRIDGE_DTMF_CHANNEL_0 | AST_BRIDGE_DTMF_CHANNEL_1))
return -2;
-
ast_mutex_lock(&c0->lock);
ast_mutex_lock(&c1->lock);
break;
case AST_CONTROL_RINGING:
#ifdef ZAPATA_PRI
- if ((p->proceeding < 2) && p->sig==SIG_PRI && p->pri && !p->outgoing) {
+ if ((!p->alerting) && p->sig==SIG_PRI && p->pri && !p->outgoing && (chan->_state != AST_STATE_UP)) {
if (p->pri->pri) {
if (!pri_grab(p, p->pri)) {
pri_acknowledge(p->pri->pri,p->call, PVT_TO_CHANNEL(p), 1);
else
ast_log(LOG_WARNING, "Unable to grab PRI on span %d\n", p->span);
}
- p->proceeding=2;
+ p->alerting=1;
}
#endif
res = tone_zone_play_tone(p->subs[index].zfd, ZT_TONE_RINGTONE);