Module: kamailio
Branch: master
Commit: ed4559a76c32d0addc14a0fae9982b081edc511b
URL: https://github.com/kamailio/kamailio/commit/ed4559a76c32d0addc14a0fae9982b0…
Author: Victor Seva <vseva(a)sipwise.com>
Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Date: 2020-02-13T09:25:31+01:00
pv_headers: store To info in xavp_parsed_name.r on replies
pvh_get_uri was using xavp_parsed_name since xavp_parsed_name.r didn't
exist so $x_tt was not there
* some refactoring to reduce duplication
* skip trying to get the same xavp when br_xname and xname are the same
* add more debug, some commented just in case We needed it later
Change-Id: I961d176204ddb5d4f726061c413be765187b27ac
---
Modified: src/modules/pv_headers/pvh_func.c
Modified: src/modules/pv_headers/pvh_xavp.c
Modified: src/modules/pv_headers/pvh_xavp.h
---
Diff: https://github.com/kamailio/kamailio/commit/ed4559a76c32d0addc14a0fae9982b0…
Patch: https://github.com/kamailio/kamailio/commit/ed4559a76c32d0addc14a0fae9982b0…
### Description
In plain Kamailio language, we used the following line:
```
if ( sdp_with_transport("RTP/SAVP") ) {
```
Now we wanted to convert that to Kemi. Turns out, the `sdp_with_transport()` function is not exported to Kemi. So we thought, we could use `sdp_transport()` to work around the missing function. This works as long as there is only one transport in SDP.
But if a phone sends two media streams in SDP, one with RTP/AVP and one with RTP/SAVP, `sdp_transport()` will return `-2`.
### Troubleshooting
#### Reproduction
Send an INVITE to Kamailio and try to get the transport type into a variable with ` sdp_transport()`. This can be done for example with a snom phone where in the rtp section of the identity configuration the parameter "RTP/SAVP" is set to "optional".
#### Log Messages
```
Jan 10 13:08:13 hagi /usr/sbin/kamailio[7136]: DEBUG: app_jsdt [app_jsdt_api.c:996]: sr_kemi_jsdt_exec_func_ex(): param[0] for: sdp_transport is str: $avp(mediaTransport)
Jan 10 13:08:13 hagi /usr/sbin/kamailio[7136]: DEBUG: <core> [core/usr_avp.c:887]: parse_avp_ident(): Parsing 'mediaTransport'
Jan 10 13:08:13 hagi /usr/sbin/kamailio[7136]: DEBUG: <core> [core/pvapi.c:368]: pv_cache_add(): pvar [$avp(mediaTransport)] added in cache
Jan 10 13:08:13 hagi /usr/sbin/kamailio[7136]: DEBUG: sdpops [sdpops_mod.c:1214]: sdp_transport_helper(): stream 0 of 0 - transport [RTP/SAVP]
Jan 10 13:08:13 hagi /usr/sbin/kamailio[7136]: DEBUG: sdpops [sdpops_mod.c:1214]: sdp_transport_helper(): stream 1 of 0 - transport [RTP/AVP]
Jan 10 13:08:13 hagi /usr/sbin/kamailio[7136]: DEBUG: sdpops [sdpops_mod.c:1219]: sdp_transport_helper(): no common transport
```
### Additional Information
We are still running Kamailio 5.1.x, but as far as I could see, the behavior has not changed since then.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2194
Module: kamailio
Branch: master
Commit: 517283c245be8c35d3c6ee9721fa1e85865b4638
URL: https://github.com/kamailio/kamailio/commit/517283c245be8c35d3c6ee9721fa1e8…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-02-12T21:29:53+01:00
presence_dialoginfo: Makefile - try to use pkg-config if xml2-config is not found
---
Modified: src/modules/presence_dialoginfo/Makefile
---
Diff: https://github.com/kamailio/kamailio/commit/517283c245be8c35d3c6ee9721fa1e8…
Patch: https://github.com/kamailio/kamailio/commit/517283c245be8c35d3c6ee9721fa1e8…
---
diff --git a/src/modules/presence_dialoginfo/Makefile b/src/modules/presence_dialoginfo/Makefile
index 32ecedfba2..93232b2e7a 100644
--- a/src/modules/presence_dialoginfo/Makefile
+++ b/src/modules/presence_dialoginfo/Makefile
@@ -1,4 +1,4 @@
-#
+#
# WARNING: do not run this directly, it should be run by the master Makefile
include ../../Makefile.defs
@@ -7,6 +7,12 @@ NAME=presence_dialoginfo.so
ifeq ($(CROSS_COMPILE),)
XML2CFG=$(shell which xml2-config)
+ifeq ($(XML2CFG),)
+XML2CFG=$(shell \
+ if pkg-config --exists libxml-2.0; then \
+ echo 'pkg-config libxml-2.0'; \
+ fi)
+endif
endif
ifneq ($(XML2CFG),)