Module: kamailio
Branch: master
Commit: 840e29d7d63602482e202e1b514a0ba9952dffe5
URL:
https://github.com/kamailio/kamailio/commit/840e29d7d63602482e202e1b514a0ba…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2019-12-04T08:20:30+01:00
core: kemi - fixed missing support to check for REFER method
---
Modified: src/core/kemi.c
---
Diff:
https://github.com/kamailio/kamailio/commit/840e29d7d63602482e202e1b514a0ba…
Patch:
https://github.com/kamailio/kamailio/commit/840e29d7d63602482e202e1b514a0ba…
---
diff --git a/src/core/kemi.c b/src/core/kemi.c
index 286e81fed0..9f477a0e17 100644
--- a/src/core/kemi.c
+++ b/src/core/kemi.c
@@ -839,6 +839,12 @@ static int sr_kemi_core_is_method_in(sip_msg_t *msg, str *vmethod)
return SR_KEMI_TRUE;
}
break;
+ case 'F':
+ case 'f':
+ if(imethod==METHOD_REFER) {
+ return SR_KEMI_TRUE;
+ }
+ break;
case 'G':
case 'g':
if(imethod==METHOD_GET) {
@@ -991,6 +997,14 @@ static int sr_kemi_core_is_method_notify(sip_msg_t *msg)
return sr_kemi_core_is_method_type(msg, METHOD_NOTIFY);
}
+/**
+ *
+ */
+static int sr_kemi_core_is_method_refer(sip_msg_t *msg)
+{
+ return sr_kemi_core_is_method_type(msg, METHOD_REFER);
+}
+
/**
*
*/
@@ -1607,6 +1621,11 @@ static sr_kemi_t _sr_kemi_core[] = {
{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
},
+ { str_init(""), str_init("is_REFER"),
+ SR_KEMIP_BOOL, sr_kemi_core_is_method_refer,
+ { SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
+ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
+ },
{ str_init(""), str_init("is_INFO"),
SR_KEMIP_BOOL, sr_kemi_core_is_method_info,
{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,