Ignore:
Timestamp:
Dec 28, 2007 8:51:58 AM (12 years ago)
Author:
bennylp
Message:

Ticket #433: Failure in media negotiation when SDP contains two audio media lines (thanks Arie Velthoen)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjmedia/src/pjmedia/session.c

    r1615 r1639  
    5454static const pj_str_t ID_IP4 = { "IP4", 3}; 
    5555static const pj_str_t ID_IP6 = { "IP6", 3}; 
    56 /*static const pj_str_t ID_RTP_AVP = { "RTP/AVP", 7 };*/ 
    57 /*static const pj_str_t ID_SDP_NAME = { "pjmedia", 7 };*/ 
     56static const pj_str_t ID_RTP_AVP = { "RTP/AVP", 7 }; 
     57static const pj_str_t ID_RTP_SAVP = { "RTP/SAVP", 8 }; 
     58//static const pj_str_t ID_SDP_NAME = { "pjmedia", 7 }; 
    5859static const pj_str_t ID_RTPMAP = { "rtpmap", 6 }; 
    5960static const pj_str_t ID_TELEPHONE_EVENT = { "telephone-event", 15 }; 
     
    181182    } 
    182183 
     184    /* Transport protocol */ 
     185 
    183186    /* Transport type must be equal */ 
    184187    if (pj_stricmp(&rem_m->desc.transport,  
     
    188191        return PJMEDIA_SDPNEG_EINVANSTP; 
    189192    } 
     193 
     194    if (pj_stricmp(&local_m->desc.transport, &ID_RTP_AVP) == 0) { 
     195 
     196        si->proto = PJMEDIA_TP_PROTO_RTP_AVP; 
     197 
     198    } else if (pj_stricmp(&local_m->desc.transport, &ID_RTP_SAVP) == 0) { 
     199 
     200        si->proto = PJMEDIA_TP_PROTO_RTP_SAVP; 
     201 
     202    } else { 
     203 
     204        si->proto = PJMEDIA_TP_PROTO_UNKNOWN; 
     205        return PJMEDIA_SDP_EINPROTO; 
     206    } 
     207 
    190208 
    191209    /* Check address family in remote SDP */ 
Note: See TracChangeset for help on using the changeset viewer.