diff --git a/net/netfilter/nft_hash.c b/net/netfilter/nft_hash.c index ea658e6c53e35b8bb0d0ffde81039ff685ccc952..eea957989708af490e6fe9d99f7c3f743d1c861f 100644 --- a/net/netfilter/nft_hash.c +++ b/net/netfilter/nft_hash.c @@ -133,7 +133,7 @@ static int nft_symhash_init(const struct nft_ctx *ctx, priv->dreg = nft_parse_register(tb[NFTA_HASH_DREG]); priv->modulus = ntohl(nla_get_be32(tb[NFTA_HASH_MODULUS])); - if (priv->modulus <= 1) + if (priv->modulus < 1) return -ERANGE; if (priv->offset + priv->modulus - 1 < priv->offset)