* [PATCH libnftnl] expr: dup: Fix json parsing
@ 2015-10-08 21:09 Aaron Conole
2015-10-12 15:55 ` Pablo Neira Ayuso
0 siblings, 1 reply; 2+ messages in thread
From: Aaron Conole @ 2015-10-08 21:09 UTC (permalink / raw)
To: netfilter-devel; +Cc: Aaron Conole, Pablo Neira Ayuso
fixes 760768890e60 ("src: rename existing functions...") by using the
correct NFTNL_TYPE_U32.
fixes 42365e5fec55 ("expr: add dup expression support...") by adding
a declaration for the ret variable.
Signed-off-by: Aaron Conole <aconole@bytheb.org>
Cc: Pablo Neira Ayuso <pablo@netfilter.org>
---
src/expr/dup.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/expr/dup.c b/src/expr/dup.c
index d0fa35f..17957df 100644
--- a/src/expr/dup.c
+++ b/src/expr/dup.c
@@ -119,10 +119,10 @@ static int nftnl_expr_dup_json_parse(struct nftnl_expr *e, json_t *root,
uint32_t sreg_addr, sreg_dev;
int datareg_type;
- ret = nftnl_jansson_parse_val(root, "sreg_addr", NFT_TYPE_U32, &sreg_addr, err);
+ int ret = nftnl_jansson_parse_val(root, "sreg_addr", NFTNL_TYPE_U32, &sreg_addr, err);
if (ret >= 0)
nftnl_expr_set_u32(e, NFTNL_EXPR_DUP_SREG_DEV, sreg_addr);
- ret = nftnl_jansson_parse_val(root, "sreg_dev", NFT_TYPE_U32, &sreg_dev, err);
+ ret = nftnl_jansson_parse_val(root, "sreg_dev", NFTNL_TYPE_U32, &sreg_dev, err);
if (ret >= 0)
nftnl_expr_set_u32(e, NFTNL_EXPR_DUP_SREG_DEV, sreg_dev);
--
1.8.3.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH libnftnl] expr: dup: Fix json parsing
2015-10-08 21:09 [PATCH libnftnl] expr: dup: Fix json parsing Aaron Conole
@ 2015-10-12 15:55 ` Pablo Neira Ayuso
0 siblings, 0 replies; 2+ messages in thread
From: Pablo Neira Ayuso @ 2015-10-12 15:55 UTC (permalink / raw)
To: Aaron Conole; +Cc: netfilter-devel
On Thu, Oct 08, 2015 at 05:09:30PM -0400, Aaron Conole wrote:
> fixes 760768890e60 ("src: rename existing functions...") by using the
> correct NFTNL_TYPE_U32.
> fixes 42365e5fec55 ("expr: add dup expression support...") by adding
> a declaration for the ret variable.
expr/dup.c: In function 'nftnl_expr_dup_json_parse':
expr/dup.c:120:6: warning: unused variable 'datareg_type'
[-Wunused-variable]
int datareg_type;
^
expr/dup.c:118:25: warning: unused variable 'dup' [-Wunused-variable]
struct nftnl_expr_dup *dup = nftnl_expr_data(e);
^
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-10-12 15:48 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-08 21:09 [PATCH libnftnl] expr: dup: Fix json parsing Aaron Conole
2015-10-12 15:55 ` Pablo Neira Ayuso
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).