Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ca39df6c authored by Patrick McHardy's avatar Patrick McHardy Committed by David S. Miller
Browse files

[NETFILTER]: ipt_TTL: fix checksum update bug



Fix regression introduced by the incremental checksum patches.

Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 5251e2d2
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -54,8 +54,8 @@ ipt_ttl_target(struct sk_buff **pskb,
	}

	if (new_ttl != iph->ttl) {
		iph->check = nf_csum_update((iph->ttl << 8) ^ 0xFFFF,
					    new_ttl << 8,
		iph->check = nf_csum_update(ntohs((iph->ttl << 8)) ^ 0xFFFF,
					    ntohs(new_ttl << 8),
					    iph->check);
		iph->ttl = new_ttl;
	}