Module: kamailio
Branch: master
Commit: 4b682e15fcd14fc3eb153865c2071162c7592220
URL:
https://github.com/kamailio/kamailio/commit/4b682e15fcd14fc3eb153865c207116…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2015-02-23T11:23:53+01:00
tls: use proper start of ipv6 address in tls.cfg
- reported by Anthony Messina
---
Modified: modules/tls/tls_config.c
---
Diff:
https://github.com/kamailio/kamailio/commit/4b682e15fcd14fc3eb153865c207116…
Patch:
https://github.com/kamailio/kamailio/commit/4b682e15fcd14fc3eb153865c207116…
---
diff --git a/modules/tls/tls_config.c b/modules/tls/tls_config.c
index 8d6b390..3960c5f 100644
--- a/modules/tls/tls_config.c
+++ b/modules/tls/tls_config.c
@@ -52,13 +52,13 @@ static int parse_ipv6(struct ip_addr* ip, cfg_token_t* token,
struct ip_addr* ipv6;
str ip6_str;
+ ip6_str.s = t.val.s;
while(1) {
ret = cfg_get_token(&t, st, 0);
if (ret != 0) goto err;
if (t.type == ']') break;
if (t.type != CFG_TOKEN_ALPHA && t.type != ':') goto err;
}
- ip6_str.s = t.val.s;
ip6_str.len = (int)(long)(t.val.s - ip6_str.s);
ipv6 = str2ip6(&ip6_str);