]> git.ipfire.org Git - thirdparty/libnftnl.git/commitdiff
rule: display position in default printf
authorEric Leblond <eric@regit.org>
Sat, 6 Jul 2013 15:33:15 +0000 (17:33 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Fri, 19 Jul 2013 11:20:50 +0000 (13:20 +0200)
Signed-off-by: Eric Leblond <eric@regit.org>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
src/rule.c

index fc34dd9e5df4f9551f656fa1501566320e1dcefc..37a085fbf8e9e4679c06a0556f38729809b6116e 100644 (file)
@@ -740,9 +740,9 @@ static int nft_rule_snprintf_default(char *buf, size_t size, struct nft_rule *r,
        struct nft_rule_expr *expr;
        int ret, len = size, offset = 0;
 
-       ret = snprintf(buf, size, "%s %s %s %"PRIu64"\n",
+       ret = snprintf(buf, size, "%s %s %s %"PRIu64" %"PRIu64"\n",
                        nft_family2str(r->family), r->table, r->chain,
-                       r->handle);
+                       r->handle, r->position);
        SNPRINTF_BUFFER_SIZE(ret, size, len, offset);
 
        list_for_each_entry(expr, &r->expr_list, head) {