Revert "sip: Specify invite contact tag"

This reverts commit 52b2afce2c.
The contact header is generated by the original sofia-sip library.
By adding the contact header explicit as user header it violates the
SIP RFC because sofia will add the Contact header to the BYE message as
well.

Let's fix the bugs in the freeswitch sofia-sip and make it compatible
(not bug compatible) with the original sofia-sip.

Change-Id: I712f17fecbc372d1e486e80673a548e281b37800
This commit is contained in:
Alexander Couzens 2020-09-05 23:08:17 +02:00
parent 52b2afce2c
commit f678caa819
1 changed files with 0 additions and 5 deletions

View File

@ -597,9 +597,6 @@ static int send_invite(struct sip_agent *agent, struct sip_call_leg *leg,
called_num,
agent->app->sip.remote_addr,
agent->app->sip.remote_port);
char *contact = talloc_asprintf(leg, "sip:%s:%d",
agent->app->sip.local_addr,
agent->app->sip.local_port);
char *sdp = sdp_create_file(leg, other, sdp_sendrecv);
leg->state = SIP_CC_INITIAL;
@ -607,7 +604,6 @@ static int send_invite(struct sip_agent *agent, struct sip_call_leg *leg,
nua_invite(leg->nua_handle,
SIPTAG_FROM_STR(from),
SIPTAG_TO_STR(to),
SIPTAG_CONTACT_STR(contact),
NUTAG_MEDIA_ENABLE(0),
SIPTAG_CONTENT_TYPE_STR("application/sdp"),
SIPTAG_PAYLOAD_STR(sdp),
@ -616,7 +612,6 @@ static int send_invite(struct sip_agent *agent, struct sip_call_leg *leg,
leg->base.call->remote = &leg->base;
talloc_free(from);
talloc_free(to);
talloc_free(contact);
talloc_free(sdp);
return 0;
}