Ignore:
Timestamp:
Dec 1, 2010 8:20:28 AM (12 years ago)
Author:
nanang
Message:

Fix #1165:

  • Fixed pjsua_media_channel_create_sdp() to re-calculate audio index of the remote offer, instead of using existing audio index calculated by pjsua_media_channel_init(), as for subsequent SDP offer/answer, pjsua_media_channel_init() may not be called.
  • Fixed SRTP transport to be able to switch SRTP status from active to inactive/by-passed and vice versa.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/src/pjsua-lib/pjsua_media.c

    r3334 r3376  
    12481248 
    12491249#if defined(PJMEDIA_HAS_SRTP) && (PJMEDIA_HAS_SRTP != 0) 
    1250         srtp_active = acc->cfg.use_srtp && srtp != NULL; 
     1250        srtp_active = acc->cfg.use_srtp; 
    12511251#else 
    12521252        srtp_active = PJ_FALSE; 
     
    13001300    if (call->med_tp == NULL) { 
    13011301        return PJ_EBUSY; 
     1302    } 
     1303 
     1304    if (rem_sdp && rem_sdp->media_count != 0) { 
     1305        pj_bool_t srtp_active; 
     1306 
     1307#if defined(PJMEDIA_HAS_SRTP) && (PJMEDIA_HAS_SRTP != 0) 
     1308        srtp_active = pjsua_var.acc[call->acc_id].cfg.use_srtp; 
     1309#else 
     1310        srtp_active = PJ_FALSE; 
     1311#endif 
     1312 
     1313        call->audio_idx = find_audio_index(rem_sdp, srtp_active); 
    13021314    } 
    13031315 
Note: See TracChangeset for help on using the changeset viewer.