path: root/include/libnftnl/chain.h
diff options
authorPhil Sutter <>2019-10-30 18:31:59 +0100
committerPhil Sutter <>2019-10-31 14:57:08 +0100
commit7349a70634fa02838aea33be0ff1b5491ac8dee9 (patch)
treec73d2368cc72cfca021f89d0c143daa869604d93 /include/libnftnl/chain.h
parent3c1a1779cb0d2725521e8411903d37b1aebd956c (diff)
Deprecate untyped data setters
These functions make assumptions on size of passed data pointer and therefore tend to hide programming mistakes. Instead either one of the type-specific setters or the generic *_set_data() setter should be used. Signed-off-by: Phil Sutter <> Acked-by: Pablo Neira Ayuso <>
Diffstat (limited to 'include/libnftnl/chain.h')
1 files changed, 1 insertions, 1 deletions
diff --git a/include/libnftnl/chain.h b/include/libnftnl/chain.h
index f84a2a3..33d04e1 100644
--- a/include/libnftnl/chain.h
+++ b/include/libnftnl/chain.h
@@ -38,7 +38,7 @@ enum nftnl_chain_attr {
bool nftnl_chain_is_set(const struct nftnl_chain *c, uint16_t attr);
void nftnl_chain_unset(struct nftnl_chain *c, uint16_t attr);
-void nftnl_chain_set(struct nftnl_chain *t, uint16_t attr, const void *data);
+void nftnl_chain_set(struct nftnl_chain *t, uint16_t attr, const void *data) __attribute__((deprecated));
int nftnl_chain_set_data(struct nftnl_chain *t, uint16_t attr,
const void *data, uint32_t data_len);
void nftnl_chain_set_u8(struct nftnl_chain *t, uint16_t attr, uint8_t data);