diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2013-10-02 14:57:29 +0200 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2013-10-02 14:57:29 +0200 |
commit | 7ccb36d3308ef57d340e663f0cabd24663f4f62a (patch) | |
tree | 131c95083d7e0f713241121d9c4a6116f71dcf78 /nest/attrs.h | |
parent | 28a10f84cbc3635e59bff348cb1715859dfacade (diff) |
Implements C.len operator for clist and eclist types.
Thanks to Sergey Popovich for the original patch.
Diffstat (limited to 'nest/attrs.h')
-rw-r--r-- | nest/attrs.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/nest/attrs.h b/nest/attrs.h index 44a23e18..a0dae221 100644 --- a/nest/attrs.h +++ b/nest/attrs.h @@ -69,6 +69,9 @@ int as_path_match(struct adata *path, struct f_path_mask *mask); static inline int int_set_get_size(struct adata *list) { return list->length / 4; } +static inline int ec_set_get_size(struct adata *list) +{ return list->length / 8; } + static inline u32 *int_set_get_data(struct adata *list) { return (u32 *) list->data; } |