[sr-dev] git:master:63cb2650: kemix: renamed functions that return empty and null string for r-uri user and host

Daniel-Constantin Mierla miconda at gmail.com
Wed Jun 5 11:51:54 CEST 2019


Module: kamailio
Branch: master
Commit: 63cb2650b65caab4326b5fbdf476bc5371eb1d30
URL: https://github.com/kamailio/kamailio/commit/63cb2650b65caab4326b5fbdf476bc5371eb1d30

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2019-06-05T11:51:24+02:00

kemix: renamed functions that return empty and null string for r-uri user and host

- set a common pattern with gete and getw in function names

---

Modified: src/modules/kemix/kemix_mod.c

---

Diff:  https://github.com/kamailio/kamailio/commit/63cb2650b65caab4326b5fbdf476bc5371eb1d30.diff
Patch: https://github.com/kamailio/kamailio/commit/63cb2650b65caab4326b5fbdf476bc5371eb1d30.patch

---

diff --git a/src/modules/kemix/kemix_mod.c b/src/modules/kemix/kemix_mod.c
index 4f69098b8b..d3464b9a42 100644
--- a/src/modules/kemix/kemix_mod.c
+++ b/src/modules/kemix/kemix_mod.c
@@ -235,7 +235,7 @@ static sr_kemi_xval_t* ki_kx_get_ruser(sip_msg_t *msg)
 /**
  *
  */
-static sr_kemi_xval_t* ki_kx_get_ruserw(sip_msg_t *msg)
+static sr_kemi_xval_t* ki_kx_getw_ruser(sip_msg_t *msg)
 {
 	return ki_kx_get_ruri_attr(msg, 1, SR_KEMI_XVAL_NULL_PRINT);
 }
@@ -243,7 +243,7 @@ static sr_kemi_xval_t* ki_kx_get_ruserw(sip_msg_t *msg)
 /**
  *
  */
-static sr_kemi_xval_t* ki_kx_get_rusere(sip_msg_t *msg)
+static sr_kemi_xval_t* ki_kx_gete_ruser(sip_msg_t *msg)
 {
 	return ki_kx_get_ruri_attr(msg, 1, SR_KEMI_XVAL_NULL_EMPTY);
 }
@@ -259,7 +259,7 @@ static sr_kemi_xval_t* ki_kx_get_rhost(sip_msg_t *msg)
 /**
  *
  */
-static sr_kemi_xval_t* ki_kx_get_rhostw(sip_msg_t *msg)
+static sr_kemi_xval_t* ki_kx_getw_rhost(sip_msg_t *msg)
 {
 	return ki_kx_get_ruri_attr(msg, 2, SR_KEMI_XVAL_NULL_PRINT);
 }
@@ -267,7 +267,7 @@ static sr_kemi_xval_t* ki_kx_get_rhostw(sip_msg_t *msg)
 /**
  *
  */
-static sr_kemi_xval_t* ki_kx_get_rhoste(sip_msg_t *msg)
+static sr_kemi_xval_t* ki_kx_gete_rhost(sip_msg_t *msg)
 {
 	return ki_kx_get_ruri_attr(msg, 2, SR_KEMI_XVAL_NULL_EMPTY);
 }
@@ -347,13 +347,13 @@ static sr_kemi_t sr_kemi_kx_exports[] = {
 		{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
 			SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
 	},
-	{ str_init("kx"), str_init("get_ruserw"),
-		SR_KEMIP_XVAL, ki_kx_get_ruserw,
+	{ str_init("kx"), str_init("getw_ruser"),
+		SR_KEMIP_XVAL, ki_kx_getw_ruser,
 		{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
 			SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
 	},
-	{ str_init("kx"), str_init("get_rusere"),
-		SR_KEMIP_XVAL, ki_kx_get_rusere,
+	{ str_init("kx"), str_init("gete_ruser"),
+		SR_KEMIP_XVAL, ki_kx_gete_ruser,
 		{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
 			SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
 	},
@@ -362,13 +362,13 @@ static sr_kemi_t sr_kemi_kx_exports[] = {
 		{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
 			SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
 	},
-	{ str_init("kx"), str_init("get_rhostw"),
-		SR_KEMIP_XVAL, ki_kx_get_rhostw,
+	{ str_init("kx"), str_init("getw_rhost"),
+		SR_KEMIP_XVAL, ki_kx_getw_rhost,
 		{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
 			SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
 	},
-	{ str_init("kx"), str_init("get_rhoste"),
-		SR_KEMIP_XVAL, ki_kx_get_rhoste,
+	{ str_init("kx"), str_init("gete_rhost"),
+		SR_KEMIP_XVAL, ki_kx_gete_rhost,
 		{ SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE,
 			SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE }
 	},




More information about the sr-dev mailing list