Hello,
On 03/10/2009 10:19 PM, Jan Janak wrote:
Module: sip-router Branch: master Commit: e8496acee788bb00f604caae59b9ca4deefd5108 URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=e8496ace...
Author: Jan Janak jan@iptel.org Committer: Jan Janak jan@iptel.org Date: Sun Mar 8 23:05:23 2009 +0100
Few kamailio compatiblity macros
New macros:
- AVP_NAME_VALUE_MASK
- AVP_CORE_MASK
- AVP_SCRIPT_MASK
The flags for scripts have to be dropped. Nobody use them, we decided that already some time ago in Kamailio. I am working in getting the PV module work with sip-router and take care of them.
Thanks, Daniel
- avp_core_flags
- avp_script_flags
- avp_get_script_flags
- is_avp_str_name
- is_avp_str_val
usr_avp.h | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-)
diff --git a/usr_avp.h b/usr_avp.h index d0f6cc6..871c310 100644 --- a/usr_avp.h +++ b/usr_avp.h @@ -157,6 +157,17 @@ typedef struct avp_spec {
#define GALIAS_CHAR_MARKER '$'
+#define AVP_NAME_VALUE_MASK 0x0007 +#define AVP_CORE_MASK 0x00ff +#define AVP_SCRIPT_MASK 0xff00 +#define avp_core_flags(f) ((f)&0x00ff) +#define avp_script_flags(f) (((f)<<8)&0xff00) +#define avp_get_script_flags(f) (((f)&0xff00)>>8)
+#define is_avp_str_name(a) ((a)->flags&AVP_NAME_STR) +#define is_avp_str_val(a) ((a)->flags&AVP_VAL_STR)
#define AVP_IS_ASSIGNABLE(ident) ( ((ident).flags & AVP_NAME_RE) == 0 && (((ident).flags & AVP_NAME) == 0 || (((ident)->flags & AVP_NAME) && (ident).name.s.len)) ) /* Initialize memory structures */ int init_avps(void);
sr-dev mailing list sr-dev@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev