diff options
author | Joshua Colp <jcolp@digium.com> | 2017-03-15 16:28:46 -0500 |
---|---|---|
committer | Gerrit Code Review <gerrit2@gerrit.digium.api> | 2017-03-15 16:28:46 -0500 |
commit | 7e8cad893fa5b3524a7f298899223cfa6d13a6b6 (patch) | |
tree | 08a33e465e4e88dffb1767d1490ae8093e5ed026 | |
parent | 2fc0c228a24096a0ca0285059d0172fcb7921fe3 (diff) | |
parent | a6dddc4a32980acf4251d3d15a11ef843e757341 (diff) |
Merge "res_pjsip_endpoint_identifier_ip: Don't output error if no header_match." into 14
-rw-r--r-- | res/res_pjsip_endpoint_identifier_ip.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/res/res_pjsip_endpoint_identifier_ip.c b/res/res_pjsip_endpoint_identifier_ip.c index 262bdc5f3..30bfc2618 100644 --- a/res/res_pjsip_endpoint_identifier_ip.c +++ b/res/res_pjsip_endpoint_identifier_ip.c @@ -140,9 +140,14 @@ static int header_identify_match_check(void *obj, void *arg, int flags) pjsip_generic_string_hdr *header; pj_str_t pj_header_name; pj_str_t pj_header_value; - char *c_header = ast_strdupa(identify->match_header); + char *c_header; char *c_value; + if (ast_strlen_zero(identify->match_header)) { + return 0; + } + + c_header = ast_strdupa(identify->match_header); c_value = strchr(c_header, ':'); if (!c_value) { ast_log(LOG_WARNING, "Identify '%s' has invalid header_match: No ':' separator found!\n", |