From bb1be65591fdbf2c57fcaf68d64ce56b34c847ad Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Tue, 29 Aug 2023 14:53:30 +0200 Subject: netlink: avoid "-Wenum-conversion" warning in dtype_map_from_kernel() Clang warns: netlink.c:806:26: error: implicit conversion from enumeration type 'enum nft_data_types' to different enumeration type 'enum datatypes' [-Werror,-Wenum-conversion] return datatype_lookup(type); ~~~~~~~~~~~~~~~ ^~~~ Signed-off-by: Thomas Haller Signed-off-by: Pablo Neira Ayuso --- src/netlink.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/netlink.c b/src/netlink.c index e1904a99..1afe162e 100644 --- a/src/netlink.c +++ b/src/netlink.c @@ -803,7 +803,7 @@ static const struct datatype *dtype_map_from_kernel(enum nft_data_types type) default: if (type & ~TYPE_MASK) return concat_type_alloc(type); - return datatype_lookup(type); + return datatype_lookup((enum datatypes) type); } } -- cgit v1.2.3