diff mbox

[nft,1/4] datatype: missing byteorder in string_type

Message ID 1418576463-3606-2-git-send-email-pablo@netfilter.org
State Accepted
Delegated to: Pablo Neira
Headers show

Commit Message

Pablo Neira Ayuso Dec. 14, 2014, 5:01 p.m. UTC
nft add rule filter input iifname { "lo", "eth0" } counter

Now the listing shows:

	iifname { "lo", "eth0"}

instead of:

	iifname { "", ""}

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
 src/datatype.c |    1 +
 1 file changed, 1 insertion(+)

Comments

Patrick McHardy Dec. 14, 2014, 6:01 p.m. UTC | #1
Am 14. Dezember 2014 18:01:00 MEZ, schrieb Pablo Neira Ayuso <pablo@netfilter.org>:
>nft add rule filter input iifname { "lo", "eth0" } counter
>
>Now the listing shows:
>
>	iifname { "lo", "eth0"}
>
>instead of:
>
>	iifname { "", ""}

Again wondering what broke this. Let me check when I am at home, IIRC we have some check for strings somewhere in the netlink code that relies in this.

>
>Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
>---
> src/datatype.c |    1 +
> 1 file changed, 1 insertion(+)
>
>diff --git a/src/datatype.c b/src/datatype.c
>index 4519d87..7f73077 100644
>--- a/src/datatype.c
>+++ b/src/datatype.c
>@@ -324,6 +324,7 @@ const struct datatype string_type = {
> 	.type		= TYPE_STRING,
> 	.name		= "string",
> 	.desc		= "string",
>+	.byteorder	= BYTEORDER_HOST_ENDIAN,
> 	.print		= string_type_print,
> 	.parse		= string_type_parse,
> };


--
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
diff mbox

Patch

diff --git a/src/datatype.c b/src/datatype.c
index 4519d87..7f73077 100644
--- a/src/datatype.c
+++ b/src/datatype.c
@@ -324,6 +324,7 @@  const struct datatype string_type = {
 	.type		= TYPE_STRING,
 	.name		= "string",
 	.desc		= "string",
+	.byteorder	= BYTEORDER_HOST_ENDIAN,
 	.print		= string_type_print,
 	.parse		= string_type_parse,
 };