[Home]

Summary:ASTERISK-14354: [patch] T38 reinvite started from Asterisk
Reporter:dcolombo (dcolombo)Labels:
Date Opened:2009-06-22 04:39:49Date Closed:2009-08-21 15:28:18
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Channels/chan_sip/T.38
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) chan_sip.patch
Description:If Asterisk starts reinvite for T38 it seems that no UPDTL frame are sent over the chan_sip.
Asterisk sends reinvite and p->t38.state's value is T38_LOCAL_REINVITE but when other peer send 200 OK in process_sdp function p->t38.state becomes T38_PEER_REINVITE but in this case  p->t38.state will never be T38_ENABLED.
Comments:By: dcolombo (dcolombo) 2009-06-22 04:47:12

Pasting here a patch that can fix the issue:

--- channels/chan_sip.orig 2009-06-22 10:44:00.000000000 +0200
+++ channels/chan_sip.c 2009-06-22 10:45:06.000000000 +0200
@@ -5291,9 +5291,11 @@ static int process_sdp(struct sip_pvt *p
numberofmediastreams++;

if (p->owner && p->lastinvite) {
- p->t38.state = T38_PEER_REINVITE; /* T38 Offered in re-invite from remote party */
- if (option_debug > 1)
- ast_log(LOG_DEBUG, "T38 state changed to %d on channel %s\n", p->t38.state, p->owner ? p->owner->name : "<none>" );
+ if(p->t38.state != T38_LOCAL_REINVITE) {
+ p->t38.state = T38_PEER_REINVITE; /* T38 Offered in re-invite from remote party */
+ if (option_debug > 1)
+ ast_log(LOG_DEBUG, "T38 state changed to %d on channel %s\n", p->t38.state, p->owner ? p->owner->name : "<none>" );
+ }
} else {
p->t38.state = T38_PEER_DIRECT; /* T38 Offered directly from peer in first invite */
p->t38.direct = 1;

By: Matteo Brancaleoni (mbrancaleoni) 2009-06-22 05:00:21

Attached patch for chan_sip on asterisk 1.4.25.1 ,
I can confirm the issue.

Basically asterisk when checks sdp does not differentiate between
a reinvite sent by peer or by asterisk itself.

By: Digium Subversion (svnbot) 2009-08-21 15:24:19

Repository: asterisk
Revision: 213631

U   branches/1.4/channels/chan_sip.c

------------------------------------------------------------------------
r213631 | kpfleming | 2009-08-21 15:24:18 -0500 (Fri, 21 Aug 2009) | 8 lines

Ensure that T.38 INVITEs generated by Asterisk properly result in T.38 being enabled.

(closes issue ASTERISK-14354)
Reported by: dcolombo
Patches:
     chan_sip.patch uploaded by mbrancaleoni (license 342)
Tested by: dcolombo, mbrancaleoni

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=213631

By: Digium Subversion (svnbot) 2009-08-21 15:24:37

Repository: asterisk
Revision: 213632

_U  trunk/

------------------------------------------------------------------------
r213632 | kpfleming | 2009-08-21 15:24:37 -0500 (Fri, 21 Aug 2009) | 14 lines

Blocked revisions 213631 via svnmerge

........
 r213631 | kpfleming | 2009-08-21 15:23:45 -0500 (Fri, 21 Aug 2009) | 8 lines
 
 Ensure that T.38 INVITEs generated by Asterisk properly result in T.38 being enabled.
 
 (closes issue ASTERISK-14354)
 Reported by: dcolombo
 Patches:
       chan_sip.patch uploaded by mbrancaleoni (license 342)
 Tested by: dcolombo, mbrancaleoni
........

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=213632