summaryrefslogtreecommitdiffstats
path: root/src/gen.c
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2019-10-30 18:31:59 +0100
committerPhil Sutter <phil@nwl.cc>2019-10-31 14:57:08 +0100
commit7349a70634fa02838aea33be0ff1b5491ac8dee9 (patch)
treec73d2368cc72cfca021f89d0c143daa869604d93 /src/gen.c
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 <phil@nwl.cc> Acked-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'src/gen.c')
-rw-r--r--src/gen.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gen.c b/src/gen.c
index 1fc9099..f2ac2ba 100644
--- a/src/gen.c
+++ b/src/gen.c
@@ -80,7 +80,7 @@ int nftnl_gen_set_data(struct nftnl_gen *gen, uint16_t attr,
return 0;
}
-EXPORT_SYMBOL(nftnl_gen_set);
+int nftnl_gen_set(struct nftnl_gen *gen, uint16_t attr, const void *data) __visible;
int nftnl_gen_set(struct nftnl_gen *gen, uint16_t attr, const void *data)
{
return nftnl_gen_set_data(gen, attr, data, nftnl_gen_validate[attr]);