diff options
author | Benny Prijono <bennylp@teluu.com> | 2007-10-06 17:55:55 +0000 |
---|---|---|
committer | Benny Prijono <bennylp@teluu.com> | 2007-10-06 17:55:55 +0000 |
commit | cb83a398ee24b9ac83a3baf4202bb44dc37f9c1e (patch) | |
tree | 7249ec13828492e2757f4ef8233a9fa8b00ba34a | |
parent | c609f7c7de23d65d99c172575b3b87a9f6f72898 (diff) |
Fixed bug: resolver did not select securer transport for SIPS URI
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@1484 74dad513-b988-da41-8d7b-12977e46ad98
-rw-r--r-- | pjsip/src/pjsip/sip_resolve.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/pjsip/src/pjsip/sip_resolve.c b/pjsip/src/pjsip/sip_resolve.c index 367d3fc4..ef0f4414 100644 --- a/pjsip/src/pjsip/sip_resolve.c +++ b/pjsip/src/pjsip/sip_resolve.c @@ -196,7 +196,18 @@ PJ_DEF(void) pjsip_resolve( pjsip_resolver_t *resolver, * In this case, full resolution must be performed. * But we don't support it (yet). */ - type = PJSIP_TRANSPORT_UDP; +#if PJ_HAS_TCP + if (target->flag & PJSIP_TRANSPORT_SECURE) + { + type = PJSIP_TRANSPORT_TLS; + } else if (target->flag & PJSIP_TRANSPORT_RELIABLE) + { + type = PJSIP_TRANSPORT_TCP; + } else +#endif + { + type = PJSIP_TRANSPORT_UDP; + } } } |