Module: kamailio
Branch: master
Commit: e049d6db78d9a86049f88acc27188d726974054f
URL:
https://github.com/kamailio/kamailio/commit/e049d6db78d9a86049f88acc27188d7…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2017-07-25T19:41:05+02:00
core: added helper fixup for int and str dynamic parameters
---
Modified: src/core/mod_fix.c
Modified: src/core/mod_fix.h
---
Diff:
https://github.com/kamailio/kamailio/commit/e049d6db78d9a86049f88acc27188d7…
Patch:
https://github.com/kamailio/kamailio/commit/e049d6db78d9a86049f88acc27188d7…
---
diff --git a/src/core/mod_fix.c b/src/core/mod_fix.c
index d817b75565..3e8562add6 100644
--- a/src/core/mod_fix.c
+++ b/src/core/mod_fix.c
@@ -461,7 +461,6 @@ int fixup_igp_pvar(void** param, int param_no)
}
-
int fixup_free_igp_pvar(void** param, int param_no)
{
if (param_no == 1)
@@ -472,7 +471,6 @@ int fixup_free_igp_pvar(void** param, int param_no)
}
-
int fixup_igp_pvar_pvar(void** param, int param_no)
{
if (param_no == 1)
@@ -483,7 +481,6 @@ int fixup_igp_pvar_pvar(void** param, int param_no)
}
-
int fixup_free_igp_pvar_pvar(void** param, int param_no)
{
if (param_no == 1)
@@ -494,6 +491,25 @@ int fixup_free_igp_pvar_pvar(void** param, int param_no)
}
+int fixup_igp_spve(void** param, int param_no)
+{
+ if (param_no == 1)
+ return fixup_igp_null(param, param_no);
+ else if (param_no == 2)
+ return fixup_spve_all(param, param_no);
+ return E_UNSPEC;
+}
+
+
+int fixup_free_igp_spve(void** param, int param_no)
+{
+ if (param_no == 1)
+ return fixup_free_igp_null(param, param_no);
+ else if (param_no == 2)
+ return fixup_free_spve_all(param, param_no);
+ return E_UNSPEC;
+}
+
/** macro for declaring a spve fixup and the corresponding free_fixup
* for a function expecting first no1 params as fparam converted spve
diff --git a/src/core/mod_fix.h b/src/core/mod_fix.h
index 835342ab86..869dd78527 100644
--- a/src/core/mod_fix.h
+++ b/src/core/mod_fix.h
@@ -122,6 +122,12 @@ int fixup_free_igp_pvar(void** param, int param_no);
int fixup_igp_pvar_pvar(void** param, int param_no);
int fixup_free_igp_pvar_pvar(void** param, int param_no);
+int fixup_igp_spve(void** param, int param_no);
+int fixup_free_igp_spve(void** param, int param_no);
+
+int fixup_pvar_all(void** param, int param_no);
+int fixup_free_pvar_all(void** param, int param_no);
+
int fixup_spve_spve(void** param, int param_no);
int fixup_free_spve_spve(void** param, int param_no);
int fixup_spve_null(void** param, int param_no);