Ignore:
Timestamp:
May 13, 2016 10:56:48 AM (5 years ago)
Author:
ming
Message:

Fixed #1918: Add API to update STUN servers and option to retry STUN for media on failure

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/src/pjsua2/endpoint.cpp

    r5288 r5297  
    15621562} 
    15631563 
     1564void Endpoint::natUpdateStunServers(const StringVector &servers, 
     1565                                    bool wait) throw(Error) 
     1566{ 
     1567    pj_str_t srv[MAX_STUN_SERVERS]; 
     1568    unsigned i, count = 0; 
     1569 
     1570    for (i=0; i<servers.size() && i<MAX_STUN_SERVERS; ++i) { 
     1571        srv[count].ptr = (char*)servers[i].c_str(); 
     1572        srv[count].slen = servers[i].size(); 
     1573        ++count; 
     1574    } 
     1575 
     1576    PJSUA2_CHECK_EXPR(pjsua_update_stun_servers(count, srv, wait) ); 
     1577} 
     1578 
    15641579void Endpoint::natCheckStunServers(const StringVector &servers, 
    15651580                                   bool wait, 
Note: See TracChangeset for help on using the changeset viewer.