From: Alvaro Neira <alvaroneay@gmail.com>
To: netfilter-devel@vger.kernel.org
Cc: eric@regit.org
Subject: [libnftables PATCH] chain: json: fix family and table error
Date: Thu, 18 Jul 2013 13:36:01 +0200 [thread overview]
Message-ID: <20130718113601.7544.7115.stgit@Ph0enix> (raw)
From: Álvaro Neira Ayuso <alvaroneay@gmail.com>
In (74ccff7 chain: json: use string to identify policy), the json support for chain was unintentionally
swapping the table name and the family.
Signed-off-by: Alvaro Neira Ayuso <alvaroneay@gmail.com>
---
0 files changed
diff --git a/src/chain.c b/src/chain.c
index 0a0e688..3c73511 100644
--- a/src/chain.c
+++ b/src/chain.c
@@ -746,8 +746,8 @@ static int nft_chain_snprintf_json(char *buf, size_t size, struct nft_chain *c)
"\"table\": \"%s\","
"\"use\": %d",
c->name, c->handle, c->bytes, c->packets,
- NFT_CHAIN_JSON_VERSION, c->table,
- nft_family2str(c->family), c->use);
+ NFT_CHAIN_JSON_VERSION, nft_family2str(c->family),
+ c->table, c->use);
SNPRINTF_BUFFER_SIZE(ret, size, len, offset);
if (c->flags & (1 << NFT_CHAIN_ATTR_HOOKNUM)) {
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next reply other threads:[~2013-07-18 11:36 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-18 11:36 Alvaro Neira [this message]
2013-07-19 10:21 ` [libnftables PATCH] chain: json: fix family and table error 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=20130718113601.7544.7115.stgit@Ph0enix \
--to=alvaroneay@gmail.com \
--cc=eric@regit.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).