|
|
|
@ -1978,7 +1978,7 @@ static int sip_call(struct ast_channel *ast, char *dest, int timeout)
|
|
|
|
|
if ( res != -1 ) {
|
|
|
|
|
p->callingpres = ast->cid.cid_pres;
|
|
|
|
|
p->jointcapability = p->capability;
|
|
|
|
|
transmit_invite(p, SIP_INVITE, 1, 1);
|
|
|
|
|
transmit_invite(p, SIP_INVITE, 1, 2);
|
|
|
|
|
if (p->maxtime) {
|
|
|
|
|
/* Initialize auto-congest time */
|
|
|
|
|
p->initid = ast_sched_add(sched, p->maxtime * 4, auto_congest, p);
|
|
|
|
@ -4529,7 +4529,10 @@ static int transmit_invite(struct sip_pvt *p, int sipmethod, int sdp, int init)
|
|
|
|
|
/* Bump branch even on initial requests */
|
|
|
|
|
p->branch ^= rand();
|
|
|
|
|
build_via(p, p->via, sizeof(p->via));
|
|
|
|
|
if (init > 1)
|
|
|
|
|
initreqprep(&req, p, sipmethod);
|
|
|
|
|
else
|
|
|
|
|
reqprep(&req, p, sipmethod, 0, 1);
|
|
|
|
|
} else
|
|
|
|
|
reqprep(&req, p, sipmethod, 0, 1);
|
|
|
|
|
|
|
|
|
@ -10654,9 +10657,9 @@ static int sip_poke_peer(struct sip_peer *peer)
|
|
|
|
|
ast_set_flag(p, SIP_OUTGOING);
|
|
|
|
|
#ifdef VOCAL_DATA_HACK
|
|
|
|
|
ast_copy_string(p->username, "__VOCAL_DATA_SHOULD_READ_THE_SIP_SPEC__", sizeof(p->username));
|
|
|
|
|
transmit_invite(p, SIP_INVITE, 0, 1);
|
|
|
|
|
transmit_invite(p, SIP_INVITE, 0, 2);
|
|
|
|
|
#else
|
|
|
|
|
transmit_invite(p, SIP_OPTIONS, 0, 1);
|
|
|
|
|
transmit_invite(p, SIP_OPTIONS, 0, 2);
|
|
|
|
|
#endif
|
|
|
|
|
gettimeofday(&peer->ps, NULL);
|
|
|
|
|
peer->pokeexpire = ast_sched_add(sched, DEFAULT_MAXMS * 2, sip_poke_noanswer, peer);
|
|
|
|
|