Module: kamailio
Branch: master
Commit: 1f7e894f5b293f97dc99e1b7e5d06159f91a96f7
URL:
https://github.com/kamailio/kamailio/commit/1f7e894f5b293f97dc99e1b7e5d0615…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2022-05-17T12:30:24+02:00
tm: fix kemi t_relay_to_proto() variants for tls
---
Modified: src/modules/tm/tm.c
---
Diff:
https://github.com/kamailio/kamailio/commit/1f7e894f5b293f97dc99e1b7e5d0615…
Patch:
https://github.com/kamailio/kamailio/commit/1f7e894f5b293f97dc99e1b7e5d0615…
---
diff --git a/src/modules/tm/tm.c b/src/modules/tm/tm.c
index 69defa1f26..b6fcc96681 100644
--- a/src/modules/tm/tm.c
+++ b/src/modules/tm/tm.c
@@ -2930,7 +2930,7 @@ static int ki_t_relay_to_proto(sip_msg_t *msg, str *sproto)
proto = PROTO_UDP;
} else if (strncasecmp(sproto->s, "TCP", 3) == 0) {
proto = PROTO_TCP;
- } else if (strncasecmp(sproto->s, "TLS", 3)) {
+ } else if (strncasecmp(sproto->s, "TLS", 3) == 0) {
proto = PROTO_TLS;
} else {
LM_ERR("bad protocol specified <%s>\n", sproto->s);
@@ -2955,7 +2955,7 @@ static int ki_t_relay_to_proto_addr(sip_msg_t *msg, str *sproto, str
*host, int
proto = PROTO_UDP;
} else if (strncasecmp(sproto->s, "TCP", 3) == 0) {
proto = PROTO_TCP;
- } else if (strncasecmp(sproto->s, "TLS", 3)) {
+ } else if (strncasecmp(sproto->s, "TLS", 3) == 0) {
proto = PROTO_TLS;
} else {
LM_ERR("bad protocol specified <%s>\n", sproto->s);