diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2018-03-05 18:07:38 +0300 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2018-03-06 14:23:33 +0300 |
commit | 0d3601d2994a4ad9edf0b44f2ea34c68ff494ea5 (patch) | |
tree | 59ca50f5f8df73d9a0f7c82339ca5d1287ad632d /net/netfilter | |
parent | ce380619fab99036f5e745c7a865b21c59f005f6 (diff) | |
download | linux-0d3601d2994a4ad9edf0b44f2ea34c68ff494ea5.tar.xz |
netfilter: nft_set_hash: skip fixed hash if timeout is specified
Fixed hash supports to timeouts, so skip it. Otherwise, userspace hits
EOPNOTSUPP.
Fixes: 6c03ae210ce3 ("netfilter: nft_set_hash: add non-resizable hashtable implementation")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net/netfilter')
-rw-r--r-- | net/netfilter/nft_set_hash.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/netfilter/nft_set_hash.c b/net/netfilter/nft_set_hash.c index 3f1624ee056f..d40591fe1b2f 100644 --- a/net/netfilter/nft_set_hash.c +++ b/net/netfilter/nft_set_hash.c @@ -674,7 +674,7 @@ static const struct nft_set_ops * nft_hash_select_ops(const struct nft_ctx *ctx, const struct nft_set_desc *desc, u32 flags) { - if (desc->size) { + if (desc->size && !(flags & NFT_SET_TIMEOUT)) { switch (desc->klen) { case 4: return &nft_hash_fast_ops; |