]> git.ipfire.org Git - thirdparty/libnftnl.git/commitdiff
set_elem: Fix return code of nftnl_set_elem_set()
authorPhil Sutter <phil@nwl.cc>
Fri, 4 Oct 2019 19:18:43 +0000 (21:18 +0200)
committerPhil Sutter <phil@nwl.cc>
Tue, 15 Oct 2019 16:28:20 +0000 (18:28 +0200)
The function returned -1 on success.

Signed-off-by: Phil Sutter <phil@nwl.cc>
Acked-by: Pablo Neira Ayuso <pablo@netfilter.org>
src/set_elem.c

index 47965249691dd828efe30f4108d5d2b9fe8c1bf5..3794f125940793ce30bd6c533ed7aaac014fbe6f 100644 (file)
@@ -149,7 +149,7 @@ int nftnl_set_elem_set(struct nftnl_set_elem *s, uint16_t attr,
                break;
        }
        s->flags |= (1 << attr);
-       return -1;
+       return 0;
 }
 
 EXPORT_SYMBOL(nftnl_set_elem_set_u32);