summaryrefslogtreecommitdiff
path: root/res/res_pjsip.c
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2014-11-04 22:31:16 +0000
committerJoshua Colp <jcolp@digium.com>2014-11-04 22:31:16 +0000
commit5e43d68717b9b6dbb4f736054bcfb74289ca41a1 (patch)
tree6414046bdd704c2a903e14dae26b3dc3c2f895ec /res/res_pjsip.c
parentbd42a09d7fcaa228d15d8bda74129232cdac4081 (diff)
res_pjsip: Allow + at the beginning of a phone number when user_eq_phone is enabled.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@427257 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'res/res_pjsip.c')
-rw-r--r--res/res_pjsip.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/res/res_pjsip.c b/res/res_pjsip.c
index 853f351f9..5aa9426d9 100644
--- a/res/res_pjsip.c
+++ b/res/res_pjsip.c
@@ -2150,6 +2150,10 @@ void ast_sip_add_usereqphone(const struct ast_sip_endpoint *endpoint, pj_pool_t
return;
}
+ if (pj_strbuf(&sip_uri->user)[0] == '+') {
+ i = 1;
+ }
+
/* Test URI user against allowed characters in AST_DIGIT_ANY */
for (; i < pj_strlen(&sip_uri->user); i++) {
if (!strchr(AST_DIGIT_ANYNUM, pj_strbuf(&sip_uri->user)[i])) {