aboutsummaryrefslogtreecommitdiffstats
path: root/net/sctp/ipv6.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sctp/ipv6.c')
-rw-r--r--net/sctp/ipv6.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/sctp/ipv6.c b/net/sctp/ipv6.c
index 6139d1d964eb..d6b585b85cbb 100644
--- a/net/sctp/ipv6.c
+++ b/net/sctp/ipv6.c
@@ -351,7 +351,7 @@ static void sctp_v6_from_skb(union sctp_addr *addr,struct sk_buff *skb,
351 int is_saddr) 351 int is_saddr)
352{ 352{
353 void *from; 353 void *from;
354 __u16 *port; 354 __be16 *port;
355 struct sctphdr *sh; 355 struct sctphdr *sh;
356 356
357 port = &addr->v6.sin6_port; 357 port = &addr->v6.sin6_port;
@@ -361,10 +361,10 @@ static void sctp_v6_from_skb(union sctp_addr *addr,struct sk_buff *skb,
361 361
362 sh = (struct sctphdr *) skb->h.raw; 362 sh = (struct sctphdr *) skb->h.raw;
363 if (is_saddr) { 363 if (is_saddr) {
364 *port = ntohs(sh->source); 364 *port = sh->source;
365 from = &skb->nh.ipv6h->saddr; 365 from = &skb->nh.ipv6h->saddr;
366 } else { 366 } else {
367 *port = ntohs(sh->dest); 367 *port = sh->dest;
368 from = &skb->nh.ipv6h->daddr; 368 from = &skb->nh.ipv6h->daddr;
369 } 369 }
370 ipv6_addr_copy(&addr->v6.sin6_addr, from); 370 ipv6_addr_copy(&addr->v6.sin6_addr, from);