summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2024-07-10 17:29:52 +0200
committerPhil Sutter <phil@nwl.cc>2024-07-10 22:28:07 +0200
commit5261d4da01e1cb9eb6cc0c90f07ca71986c5a23b (patch)
tree7f53302febad979d9556bdbc7887edfe473400ba
parent490bc700fdef5d589399277a8bfd13eec5ca9636 (diff)
table: Support unsetting NFTNL_TABLE_USERDATA attribute
Cosmetics, but support unsetting anything that may be set. Fixes: 99be0e6d066d7 ("table: add userdata support") Signed-off-by: Phil Sutter <phil@nwl.cc>
-rw-r--r--src/table.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/table.c b/src/table.c
index 13f01cf..1a5f6f3 100644
--- a/src/table.c
+++ b/src/table.c
@@ -74,6 +74,9 @@ void nftnl_table_unset(struct nftnl_table *t, uint16_t attr)
case NFTNL_TABLE_NAME:
xfree(t->name);
break;
+ case NFTNL_TABLE_USERDATA:
+ xfree(t->user.data);
+ break;
case NFTNL_TABLE_FLAGS:
case NFTNL_TABLE_HANDLE:
case NFTNL_TABLE_FAMILY: