summaryrefslogtreecommitdiff
path: root/res
diff options
context:
space:
mode:
authorzuul <zuul@gerrit.asterisk.org>2016-05-12 14:25:43 -0500
committerGerrit Code Review <gerrit2@gerrit.digium.api>2016-05-12 14:25:43 -0500
commitdd354009d3c64499640a0297703f5619e2cd5007 (patch)
treebcb8a00ee433fd63bd0e8f73301adf655e75ded4 /res
parent5236ffed97bf5d4a6b54cfefd672f9dc31f0a563 (diff)
parentd14d1ba826f8ac7f340fd67df41ed2c5dcd17539 (diff)
Merge "res_pjsip_outbound_registration: generate correct Contact URI for TLS"
Diffstat (limited to 'res')
-rw-r--r--res/res_pjsip_outbound_registration.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/res/res_pjsip_outbound_registration.c b/res/res_pjsip_outbound_registration.c
index f85996ed5..815432d10 100644
--- a/res/res_pjsip_outbound_registration.c
+++ b/res/res_pjsip_outbound_registration.c
@@ -1096,7 +1096,7 @@ static int sip_dialog_create_contact(pj_pool_t *pool, pj_str_t *contact, const c
contact->ptr = pj_pool_alloc(pool, PJSIP_MAX_URL_SIZE);
contact->slen = pj_ansi_snprintf(contact->ptr, PJSIP_MAX_URL_SIZE,
"<%s:%s@%s%.*s%s:%d%s%s%s%s>",
- (pjsip_transport_get_flag_from_type(type) & PJSIP_TRANSPORT_SECURE) ? "sips" : "sip",
+ ((pjsip_transport_get_flag_from_type(type) & PJSIP_TRANSPORT_SECURE) && PJSIP_URI_SCHEME_IS_SIPS(uri)) ? "sips" : "sip",
user,
(type & PJSIP_TRANSPORT_IPV6) ? "[" : "",
(int)local_addr.slen,