|
@@ -158,8 +158,8 @@ int ip_build_and_send_pkt(struct sk_buff *skb, struct sock *sk,
|
|
else
|
|
else
|
|
iph->frag_off = 0;
|
|
iph->frag_off = 0;
|
|
iph->ttl = ip_select_ttl(inet, &rt->dst);
|
|
iph->ttl = ip_select_ttl(inet, &rt->dst);
|
|
- iph->daddr = rt->rt_dst;
|
|
|
|
- iph->saddr = rt->rt_src;
|
|
|
|
|
|
+ iph->daddr = (opt && opt->opt.srr ? opt->opt.faddr : daddr);
|
|
|
|
+ iph->saddr = saddr;
|
|
iph->protocol = sk->sk_protocol;
|
|
iph->protocol = sk->sk_protocol;
|
|
ip_select_ident(iph, &rt->dst, sk);
|
|
ip_select_ident(iph, &rt->dst, sk);
|
|
|
|
|