diff options
Diffstat (limited to 'libnfnetlink.h')
-rw-r--r-- | libnfnetlink.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/libnfnetlink.h b/libnfnetlink.h index 9761eed..ebf61f2 100644 --- a/libnfnetlink.h +++ b/libnfnetlink.h @@ -30,8 +30,9 @@ extern int nfnl_close(struct nfnl_handle *); extern int nfnl_send(struct nfnl_handle *, struct nlmsghdr *); -extern void nfnl_fill_hdr(struct nfnl_handle *, struct nlmsghdr *, int, - u_int8_t, u_int16_t, u_int16_t); +extern void nfnl_fill_hdr(struct nfnl_handle *, struct nlmsghdr *, + unsigned int, u_int8_t, u_int16_t, u_int16_t, + u_int16_t); extern int nfnl_listen(struct nfnl_handle *, int (*)(struct sockaddr_nl *, struct nlmsghdr *, void *), @@ -48,6 +49,8 @@ extern int nfnl_addattr32(struct nlmsghdr *, int, int, u_int32_t); extern int nfnl_nfa_addattr_l(struct nfattr *, int, int, void *, int); extern int nfnl_nfa_addattr32(struct nfattr *, int, int, u_int32_t); extern int nfnl_parse_attr(struct nfattr **, int, struct nfattr *, int); +#define nfnl_parse_nested(tb, max, nfa) \ + nfnl_parse_attr((tb), (max), NFA_DATA((nfa)), NFA_PAYLOAD((nfa))) #define nfnl_nest(nlh, bufsize, type) \ ({ struct nfattr *__start = NLMSG_TAIL(nlh); \ nfnl_addattr_l(nlh, bufsize, type, NULL, 0); \ |