netfilter: nf_tables: add NFT_CHAIN_POLICY_UNSET and use it
Default policy is defined as a unsigned 8-bit field, do not use a negative value to leave it unset, use this new NFT_CHAIN_POLICY_UNSET instead. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
@@ -1715,7 +1715,7 @@ static int nf_tables_addchain(struct nft_ctx *ctx, u8 family, u8 genmask,
|
||||
goto err2;
|
||||
}
|
||||
|
||||
nft_trans_chain_policy(trans) = -1;
|
||||
nft_trans_chain_policy(trans) = NFT_CHAIN_POLICY_UNSET;
|
||||
if (nft_is_base_chain(chain))
|
||||
nft_trans_chain_policy(trans) = policy;
|
||||
|
||||
|
Reference in New Issue
Block a user