Revert "netfilter: ctnetlink: use helper function to calculate expect ID"

This reverts commit 42ea0c1913.
This commit is contained in:
Ksawlii 2024-11-24 00:23:56 +01:00
parent 683ecba589
commit ddb8f59b0a

View file

@ -3413,8 +3413,7 @@ static int ctnetlink_del_expect(struct net *net, struct sock *ctnl,
if (cda[CTA_EXPECT_ID]) {
__be32 id = nla_get_be32(cda[CTA_EXPECT_ID]);
if (id != nf_expect_get_id(exp)) {
if (ntohl(id) != (u32)(unsigned long)exp) {
nf_ct_expect_put(exp);
return -ENOENT;
}