diff options
author | Benny Prijono <bennylp@teluu.com> | 2009-08-12 11:03:23 +0000 |
---|---|---|
committer | Benny Prijono <bennylp@teluu.com> | 2009-08-12 11:03:23 +0000 |
commit | 8df6724ddca5de98cfdc21316fb5d7e5de95d726 (patch) | |
tree | e48368d28208f4454071f196f49f7cddf3b0e9ba /pjsip/src/pjsua-lib/pjsua_media.c | |
parent | c4851558e0c60e8a8929473631b825e1945f239b (diff) |
Ticket #866: Allow application to specify more than one STUN servers for more robustness, and continue application startup if STUN resolution fails
PJSUA-LIB:
- New fields in pjsua_config to specify more than one STUN servers (the stun_srv_cnt and stun_srv array)
- The existing stun_host and stun_domain fields are deprecated, but backward compatibility is maintained. If stun_srv_cnt is zero, the library will import the entries from stun_host and stun_domain
- The library will now resolve the STUN server entries one by one and test it before using it
- New auxiliary API pjsua_resolve_stun_servers() to perform resolution and test against array of STUN servers
pjsua application:
- The "stun-srv" command line options can now be specified more than once
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@2864 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip/src/pjsua-lib/pjsua_media.c')
-rw-r--r-- | pjsip/src/pjsua-lib/pjsua_media.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pjsip/src/pjsua-lib/pjsua_media.c b/pjsip/src/pjsua-lib/pjsua_media.c index b4d39711..7b95a137 100644 --- a/pjsip/src/pjsua-lib/pjsua_media.c +++ b/pjsip/src/pjsua-lib/pjsua_media.c @@ -359,7 +359,7 @@ static pj_status_t create_rtp_rtcp_sock(const pjsua_transport_config *cfg, pj_sock_t sock[2]; /* Make sure STUN server resolution has completed */ - status = pjsua_resolve_stun_server(PJ_TRUE); + status = resolve_stun_server(PJ_TRUE); if (status != PJ_SUCCESS) { pjsua_perror(THIS_FILE, "Error resolving STUN server", status); return status; @@ -860,7 +860,7 @@ static pj_status_t create_ice_media_transports(void) pj_status_t status; /* Make sure STUN server resolution has completed */ - status = pjsua_resolve_stun_server(PJ_TRUE); + status = resolve_stun_server(PJ_TRUE); if (status != PJ_SUCCESS) { pjsua_perror(THIS_FILE, "Error resolving STUN server", status); return status; |