aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/icmp.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv6/icmp.c')
-rw-r--r--net/ipv6/icmp.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/net/ipv6/icmp.c b/net/ipv6/icmp.c
index 90868fb42757..9e2bdccf9143 100644
--- a/net/ipv6/icmp.c
+++ b/net/ipv6/icmp.c
@@ -290,9 +290,9 @@ static void mip6_addr_swap(struct sk_buff *skb)
290 if (likely(off >= 0)) { 290 if (likely(off >= 0)) {
291 hao = (struct ipv6_destopt_hao *) 291 hao = (struct ipv6_destopt_hao *)
292 (skb_network_header(skb) + off); 292 (skb_network_header(skb) + off);
293 ipv6_addr_copy(&tmp, &iph->saddr); 293 tmp = iph->saddr;
294 ipv6_addr_copy(&iph->saddr, &hao->addr); 294 iph->saddr = hao->addr;
295 ipv6_addr_copy(&hao->addr, &tmp); 295 hao->addr = tmp;
296 } 296 }
297 } 297 }
298} 298}
@@ -444,9 +444,9 @@ void icmpv6_send(struct sk_buff *skb, u8 type, u8 code, __u32 info)
444 444
445 memset(&fl6, 0, sizeof(fl6)); 445 memset(&fl6, 0, sizeof(fl6));
446 fl6.flowi6_proto = IPPROTO_ICMPV6; 446 fl6.flowi6_proto = IPPROTO_ICMPV6;
447 ipv6_addr_copy(&fl6.daddr, &hdr->saddr); 447 fl6.daddr = hdr->saddr;
448 if (saddr) 448 if (saddr)
449 ipv6_addr_copy(&fl6.saddr, saddr); 449 fl6.saddr = *saddr;
450 fl6.flowi6_oif = iif; 450 fl6.flowi6_oif = iif;
451 fl6.fl6_icmp_type = type; 451 fl6.fl6_icmp_type = type;
452 fl6.fl6_icmp_code = code; 452 fl6.fl6_icmp_code = code;
@@ -538,9 +538,9 @@ static void icmpv6_echo_reply(struct sk_buff *skb)
538 538
539 memset(&fl6, 0, sizeof(fl6)); 539 memset(&fl6, 0, sizeof(fl6));
540 fl6.flowi6_proto = IPPROTO_ICMPV6; 540 fl6.flowi6_proto = IPPROTO_ICMPV6;
541 ipv6_addr_copy(&fl6.daddr, &ipv6_hdr(skb)->saddr); 541 fl6.daddr = ipv6_hdr(skb)->saddr;
542 if (saddr) 542 if (saddr)
543 ipv6_addr_copy(&fl6.saddr, saddr); 543 fl6.saddr = *saddr;
544 fl6.flowi6_oif = skb->dev->ifindex; 544 fl6.flowi6_oif = skb->dev->ifindex;
545 fl6.fl6_icmp_type = ICMPV6_ECHO_REPLY; 545 fl6.fl6_icmp_type = ICMPV6_ECHO_REPLY;
546 security_skb_classify_flow(skb, flowi6_to_flowi(&fl6)); 546 security_skb_classify_flow(skb, flowi6_to_flowi(&fl6));
@@ -786,8 +786,8 @@ void icmpv6_flow_init(struct sock *sk, struct flowi6 *fl6,
786 int oif) 786 int oif)
787{ 787{
788 memset(fl6, 0, sizeof(*fl6)); 788 memset(fl6, 0, sizeof(*fl6));
789 ipv6_addr_copy(&fl6->saddr, saddr); 789 fl6->saddr = *saddr;
790 ipv6_addr_copy(&fl6->daddr, daddr); 790 fl6->daddr = *daddr;
791 fl6->flowi6_proto = IPPROTO_ICMPV6; 791 fl6->flowi6_proto = IPPROTO_ICMPV6;
792 fl6->fl6_icmp_type = type; 792 fl6->fl6_icmp_type = type;
793 fl6->fl6_icmp_code = 0; 793 fl6->fl6_icmp_code = 0;