X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=net%2Fsctp%2Fprotocol.c;h=d08bafd4439e6ac5031f67569ddd69b21274ec01;hb=d55c41b115e74b30a3d1a61db806bd03bdd9dd6f;hp=d1fbd1f5c6d16a28bab3daffbced1037f1915f71;hpb=9b1dfad011d409bc56476a81810342751645ee54;p=~andy%2Flinux diff --git a/net/sctp/protocol.c b/net/sctp/protocol.c index d1fbd1f5c6d..d08bafd4439 100644 --- a/net/sctp/protocol.c +++ b/net/sctp/protocol.c @@ -252,7 +252,7 @@ static void sctp_v4_from_skb(union sctp_addr *addr, struct sk_buff *skb, int is_saddr) { void *from; - __u16 *port; + __be16 *port; struct sctphdr *sh; port = &addr->v4.sin_port; @@ -260,10 +260,10 @@ static void sctp_v4_from_skb(union sctp_addr *addr, struct sk_buff *skb, sh = (struct sctphdr *) skb->h.raw; if (is_saddr) { - *port = ntohs(sh->source); + *port = sh->source; from = &skb->nh.iph->saddr; } else { - *port = ntohs(sh->dest); + *port = sh->dest; from = &skb->nh.iph->daddr; } memcpy(&addr->v4.sin_addr.s_addr, from, sizeof(struct in_addr));