Ignore:
Timestamp:
Jun 26, 2008 3:48:14 PM (16 years ago)
Author:
bennylp
Message:

Specifying star in codec selection will select all codecs. Fixed the codec selection in codec.c to select all codecs when empty string is given.

File:
1 edited

Legend:

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

    r2039 r2061  
    22282228                                              pj_uint8_t priority ) 
    22292229{ 
     2230    const pj_str_t all = { NULL, 0 }; 
    22302231    pjmedia_codec_mgr *codec_mgr; 
    22312232 
    22322233    codec_mgr = pjmedia_endpt_get_codec_mgr(pjsua_var.med_endpt); 
     2234 
     2235    if (codec_id->slen==1 && *codec_id->ptr=='*') 
     2236        codec_id = &all; 
    22332237 
    22342238    return pjmedia_codec_mgr_set_codec_priority(codec_mgr, codec_id,  
     
    22432247                                           pjmedia_codec_param *param ) 
    22442248{ 
     2249    const pj_str_t all = { NULL, 0 }; 
    22452250    const pjmedia_codec_info *info; 
    22462251    pjmedia_codec_mgr *codec_mgr; 
     
    22502255    codec_mgr = pjmedia_endpt_get_codec_mgr(pjsua_var.med_endpt); 
    22512256 
     2257    if (codec_id->slen==1 && *codec_id->ptr=='*') 
     2258        codec_id = &all; 
     2259 
    22522260    status = pjmedia_codec_mgr_find_codecs_by_id(codec_mgr, codec_id, 
    22532261                                                 &count, &info, NULL); 
Note: See TracChangeset for help on using the changeset viewer.