From d7955867a79e8aed8058a2a69953c6005bb9ef5a Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Sun, 24 Nov 2013 21:01:49 +0100 Subject: src: consolidate netlink build header function Add new function nft_nlmsg_build_hdr which consolidates all existing functions to build headers per object. They basically look the same. This patch still provides aliases for consistency in the naming approach. Signed-off-by: Pablo Neira Ayuso --- include/libnftables/rule.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/libnftables/rule.h') diff --git a/include/libnftables/rule.h b/include/libnftables/rule.h index d1d75e1..86dbc17 100644 --- a/include/libnftables/rule.h +++ b/include/libnftables/rule.h @@ -51,7 +51,7 @@ int nft_rule_parse(struct nft_rule *r, enum nft_parse_type type, const char *dat int nft_rule_snprintf(char *buf, size_t size, struct nft_rule *t, uint32_t type, uint32_t flags); int nft_rule_fprintf(FILE *fp, struct nft_rule *r, uint32_t type, uint32_t flags); -struct nlmsghdr *nft_rule_nlmsg_build_hdr(char *buf, uint16_t cmd, uint16_t family, uint16_t type, uint32_t seq); +#define nft_rule_nlmsg_build_hdr nft_nlmsg_build_hdr int nft_rule_nlmsg_parse(const struct nlmsghdr *nlh, struct nft_rule *t); int nft_rule_expr_foreach(struct nft_rule *r, -- cgit v1.2.3