Module: kamailio
Branch: master
Commit: 21eeb977c882dec4540703b2d8b4ff5131e6c446
URL:
https://github.com/kamailio/kamailio/commit/21eeb977c882dec4540703b2d8b4ff5…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2023-11-02T14:01:58+01:00
core: add transport parameter for ws/wss advertised proto
---
Modified: src/core/msg_translator.c
---
Diff:
https://github.com/kamailio/kamailio/commit/21eeb977c882dec4540703b2d8b4ff5…
Patch:
https://github.com/kamailio/kamailio/commit/21eeb977c882dec4540703b2d8b4ff5…
---
diff --git a/src/core/msg_translator.c b/src/core/msg_translator.c
index f5f7be8c9f9..9bb142efea8 100644
--- a/src/core/msg_translator.c
+++ b/src/core/msg_translator.c
@@ -1094,6 +1094,9 @@ void process_lumps(struct sip_msg *msg, struct lump *lumps, char
*new_buf,
break; \
case PROTO_WS: \
case PROTO_WSS: \
+ memcpy(new_buf + offset, TRANSPORT_PARAM, \
+ TRANSPORT_PARAM_LEN); \
+ offset += TRANSPORT_PARAM_LEN; \
memcpy(new_buf + offset, "ws", 2); \
offset += 2; \
break; \
@@ -1217,6 +1220,9 @@ void process_lumps(struct sip_msg *msg, struct lump *lumps, char
*new_buf,
break; \
case PROTO_WS: \
case PROTO_WSS: \
+ memcpy(new_buf + offset, TRANSPORT_PARAM, \
+ TRANSPORT_PARAM_LEN); \
+ offset += TRANSPORT_PARAM_LEN; \
memcpy(new_buf + offset, "ws", 2); \
offset += 2; \
break; \