From: Arturo Borrero Gonzalez <arturo.borrero.glez@gmail.com>
To: netfilter-devel@vger.kernel.org
Subject: [nft PATCH] mnl: fix name of called build_hdr functions
Date: Mon, 02 Dec 2013 17:07:18 +0100 [thread overview]
Message-ID: <20131202160718.19252.73477.stgit@nfdev.cica.es> (raw)
I think that using the right keyword improves readability.
Minor fix, given that all those functions are aliases.
Signed-off-by: Arturo Borrero Gonzalez <arturo.borrero.glez@gmail.com>
---
src/mnl.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/src/mnl.c b/src/mnl.c
index 27b181a..2f27b17 100644
--- a/src/mnl.c
+++ b/src/mnl.c
@@ -270,7 +270,7 @@ int mnl_nft_rule_batch_add(struct nft_rule *nlr, unsigned int flags,
{
struct nlmsghdr *nlh;
- nlh = nft_table_nlmsg_build_hdr(mnl_nlmsg_batch_current(batch),
+ nlh = nft_rule_nlmsg_build_hdr(mnl_nlmsg_batch_current(batch),
NFT_MSG_NEWRULE,
nft_rule_attr_get_u32(nlr, NFT_RULE_ATTR_FAMILY),
flags|NLM_F_ACK|NLM_F_CREATE, seqnum);
@@ -287,7 +287,7 @@ int mnl_nft_rule_batch_del(struct nft_rule *nlr, unsigned int flags,
{
struct nlmsghdr *nlh;
- nlh = nft_table_nlmsg_build_hdr(mnl_nlmsg_batch_current(batch),
+ nlh = nft_rule_nlmsg_build_hdr(mnl_nlmsg_batch_current(batch),
NFT_MSG_DELRULE,
nft_rule_attr_get_u32(nlr, NFT_RULE_ATTR_FAMILY),
NLM_F_ACK, seqnum);
@@ -309,7 +309,7 @@ int mnl_nft_rule_add(struct mnl_socket *nf_sock, struct nft_rule *nlr,
char buf[MNL_SOCKET_BUFFER_SIZE];
struct nlmsghdr *nlh;
- nlh = nft_table_nlmsg_build_hdr(buf, NFT_MSG_NEWRULE,
+ nlh = nft_rule_nlmsg_build_hdr(buf, NFT_MSG_NEWRULE,
nft_rule_attr_get_u32(nlr, NFT_RULE_ATTR_FAMILY),
flags|NLM_F_ACK|NLM_F_CREATE, seq);
nft_rule_nlmsg_build_payload(nlh, nlr);
@@ -323,7 +323,7 @@ int mnl_nft_rule_delete(struct mnl_socket *nf_sock, struct nft_rule *nlr,
char buf[MNL_SOCKET_BUFFER_SIZE];
struct nlmsghdr *nlh;
- nlh = nft_table_nlmsg_build_hdr(buf, NFT_MSG_DELRULE,
+ nlh = nft_rule_nlmsg_build_hdr(buf, NFT_MSG_DELRULE,
nft_rule_attr_get_u32(nlr, NFT_RULE_ATTR_FAMILY),
NLM_F_ACK, seq);
nft_rule_nlmsg_build_payload(nlh, nlr);
@@ -385,7 +385,7 @@ int mnl_nft_chain_add(struct mnl_socket *nf_sock, struct nft_chain *nlc,
char buf[MNL_SOCKET_BUFFER_SIZE];
struct nlmsghdr *nlh;
- nlh = nft_table_nlmsg_build_hdr(buf, NFT_MSG_NEWCHAIN,
+ nlh = nft_chain_nlmsg_build_hdr(buf, NFT_MSG_NEWCHAIN,
nft_chain_attr_get_u32(nlc, NFT_CHAIN_ATTR_FAMILY),
NLM_F_ACK|flags, seq);
nft_chain_nlmsg_build_payload(nlh, nlc);
@@ -399,7 +399,7 @@ int mnl_nft_chain_delete(struct mnl_socket *nf_sock, struct nft_chain *nlc,
char buf[MNL_SOCKET_BUFFER_SIZE];
struct nlmsghdr *nlh;
- nlh = nft_table_nlmsg_build_hdr(buf, NFT_MSG_DELCHAIN,
+ nlh = nft_chain_nlmsg_build_hdr(buf, NFT_MSG_DELCHAIN,
nft_chain_attr_get_u32(nlc, NFT_CHAIN_ATTR_FAMILY),
NLM_F_ACK, seq);
nft_chain_nlmsg_build_payload(nlh, nlc);
@@ -463,7 +463,7 @@ int mnl_nft_chain_get(struct mnl_socket *nf_sock, struct nft_chain *nlc,
char buf[MNL_SOCKET_BUFFER_SIZE];
struct nlmsghdr *nlh;
- nlh = nft_table_nlmsg_build_hdr(buf, NFT_MSG_GETCHAIN,
+ nlh = nft_chain_nlmsg_build_hdr(buf, NFT_MSG_GETCHAIN,
nft_chain_attr_get_u32(nlc, NFT_CHAIN_ATTR_FAMILY),
NLM_F_ACK|flags, seq);
nft_chain_nlmsg_build_payload(nlh, nlc);
next reply other threads:[~2013-12-02 16:07 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-02 16:07 Arturo Borrero Gonzalez [this message]
2013-12-04 11:16 ` [nft PATCH] mnl: fix name of called build_hdr functions Pablo Neira Ayuso
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131202160718.19252.73477.stgit@nfdev.cica.es \
--to=arturo.borrero.glez@gmail.com \
--cc=netfilter-devel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.