netfilter: nft_reject_bridge: remove unnecessary ttl set

In the nft_reject_br_send_v4_tcp_reset(), a ttl is set by the
nf_reject_iphdr_put(). so, below code is unnecessary.

Signed-off-by: Taehee Yoo <ap420073@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
Taehee Yoo 2018-06-12 01:54:47 +09:00 коммит произвёл Pablo Neira Ayuso
Родитель aea06eb276
Коммит 6542df2f84
1 изменённых файлов: 1 добавлений и 2 удалений

Просмотреть файл

@ -89,8 +89,7 @@ static void nft_reject_br_send_v4_tcp_reset(struct net *net,
niph = nf_reject_iphdr_put(nskb, oldskb, IPPROTO_TCP, niph = nf_reject_iphdr_put(nskb, oldskb, IPPROTO_TCP,
net->ipv4.sysctl_ip_default_ttl); net->ipv4.sysctl_ip_default_ttl);
nf_reject_ip_tcphdr_put(nskb, oldskb, oth); nf_reject_ip_tcphdr_put(nskb, oldskb, oth);
niph->ttl = net->ipv4.sysctl_ip_default_ttl; niph->tot_len = htons(nskb->len);
niph->tot_len = htons(nskb->len);
ip_send_check(niph); ip_send_check(niph);
nft_reject_br_push_etherhdr(oldskb, nskb); nft_reject_br_push_etherhdr(oldskb, nskb);