Skip to content
Snippets Groups Projects
Commit 45dfc612 authored by Joshua Colp's avatar Joshua Colp
Browse files

Merged revisions 91439 via svnmerge from

https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91439 | file | 2007-12-06 12:14:26 -0400 (Thu, 06 Dec 2007) | 4 lines

Add support for accepting and sending T.38 in the initial INVITE.
(closes issue #9402)
Reported by: thdei

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@91440 65c4cc65-6c06-0410-ace0-fbb531ad65f3
parent 10522820
No related branches found
No related tags found
No related merge requests found
...@@ -4723,6 +4723,10 @@ static struct ast_channel *sip_new(struct sip_pvt *i, int state, const char *tit ...@@ -4723,6 +4723,10 @@ static struct ast_channel *sip_new(struct sip_pvt *i, int state, const char *tit
if (i->rtp) if (i->rtp)
ast_jb_configure(tmp, &global_jbconf); ast_jb_configure(tmp, &global_jbconf);
   
/* If the INVITE contains T.38 SDP information set the proper channel variable so a created outgoing call will also have T.38 */
if (i->udptl && i->t38.state == T38_PEER_DIRECT)
pbx_builtin_setvar_helper(tmp, "_T38CALL", "1");
/* Set channel variables for this call from configuration */ /* Set channel variables for this call from configuration */
for (v = i->chanvars ; v ; v = v->next) for (v = i->chanvars ; v ; v = v->next)
pbx_builtin_setvar_helper(tmp, v->name, v->value); pbx_builtin_setvar_helper(tmp, v->name, v->value);
...@@ -13613,6 +13617,20 @@ static void handle_response_invite(struct sip_pvt *p, int resp, char *rest, stru ...@@ -13613,6 +13617,20 @@ static void handle_response_invite(struct sip_pvt *p, int resp, char *rest, stru
if (p->owner && !req->ignore) if (p->owner && !req->ignore)
ast_queue_control(p->owner, AST_CONTROL_CONGESTION); ast_queue_control(p->owner, AST_CONTROL_CONGESTION);
p->needdestroy = 1; p->needdestroy = 1;
} else if (p->udptl && p->t38.state == T38_LOCAL_DIRECT) {
/* We tried to send T.38 out in an initial INVITE and the remote side rejected it,
right now we can't fall back to audio so totally abort.
*/
p->t38.state = T38_DISABLED;
/* Try to reset RTP timers */
ast_rtp_set_rtptimers_onhold(p->rtp);
ast_log(LOG_ERROR, "Got error on T.38 initial invite. Bailing out.\n");
/* The dialog is now terminated */
if (p->owner && !req->ignore)
ast_queue_control(p->owner, AST_CONTROL_CONGESTION);
p->needdestroy = 1;
sip_alreadygone(p);
} else { } else {
/* We can't set up this call, so give up */ /* We can't set up this call, so give up */
if (p->owner && !req->ignore) if (p->owner && !req->ignore)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment