build: remove support for Linux 2.6.20

This commit is contained in:
Jan Engelhardt
2012-10-15 23:24:07 +02:00
parent e640a15ec9
commit 31aebc134e
5 changed files with 3 additions and 37 deletions

View File

@@ -237,15 +237,9 @@ static void tarpit_tcp4(struct sk_buff *oldskb, unsigned int hook,
/* Adjust TCP checksum */
tcph->check = 0;
#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 20)
tcph->check = tcp_v4_check(tcph, sizeof(struct tcphdr), niph->saddr,
niph->daddr, csum_partial((char *)tcph,
sizeof(struct tcphdr), 0));
#else
tcph->check = tcp_v4_check(sizeof(struct tcphdr), niph->saddr,
niph->daddr, csum_partial((char *)tcph,
sizeof(struct tcphdr), 0));
#endif
/* Set DF, id = 0 */
niph->frag_off = htons(IP_DF);