[sr-dev] git:master:b97a8f46: core: kemi - exported KSR.isdsturiset() function
Daniel-Constantin Mierla
miconda at gmail.com
Wed Apr 27 16:41:29 CEST 2016
Module: kamailio
Branch: master
Commit: b97a8f46efc4f9a7f5577064cd4f0d401864c598
URL: https://github.com/kamailio/kamailio/commit/b97a8f46efc4f9a7f5577064cd4f0d401864c598
Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2016-04-27T16:22:39+02:00
core: kemi - exported KSR.isdsturiset() function
---
Modified: kemi.c
---
Diff: https://github.com/kamailio/kamailio/commit/b97a8f46efc4f9a7f5577064cd4f0d401864c598.diff
Patch: https://github.com/kamailio/kamailio/commit/b97a8f46efc4f9a7f5577064cd4f0d401864c598.patch
---
diff --git a/kemi.c b/kemi.c
index 3ceaad6..7b08a83 100644
--- a/kemi.c
+++ b/kemi.c
@@ -420,6 +420,22 @@ static int sr_kemi_core_resetdsturi(sip_msg_t *msg)
/**
*
*/
+static int sr_kemi_core_isdsturiset(sip_msg_t *msg)
+{
+ if(msg==NULL) {
+ LM_WARN("invalid msg parameter\n");
+ return SR_KEMI_FALSE;
+ }
+
+ if(msg->dst_uri.s!=NULL && msg->dst_uri.len>0) {
+ return SR_KEMI_TRUE;
+ }
+ return SR_KEMI_FALSE;
+}
+
+/**
+ *
+ */
static int sr_kemi_core_force_rport(sip_msg_t *msg)
{
if(msg==NULL) {
@@ -535,6 +551,11 @@ static sr_kemi_t _sr_kemi_core[] = {
{ SR_KEMIP_STR, SR_KEMIP_NONE, SR_KEMIP_NONE,
SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
},
+ { str_init(""), str_init("isdsturiset"),
+ SR_KEMIP_BOOL, sr_kemi_core_isdsturiset,
+ { SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
+ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
+ },
{ str_init(""), str_init("force_rport"),
SR_KEMIP_BOOL, sr_kemi_core_force_rport,
{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
More information about the sr-dev
mailing list