diff options
Diffstat (limited to 'net/sctp/input.c')
-rw-r--r-- | net/sctp/input.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/sctp/input.c b/net/sctp/input.c index 6d82f400d13c..33111873a488 100644 --- a/net/sctp/input.c +++ b/net/sctp/input.c | |||
@@ -726,7 +726,7 @@ static struct sctp_endpoint *__sctp_rcv_lookup_endpoint(const union sctp_addr *l | |||
726 | struct sctp_endpoint *ep; | 726 | struct sctp_endpoint *ep; |
727 | int hash; | 727 | int hash; |
728 | 728 | ||
729 | hash = sctp_ep_hashfn(laddr->v4.sin_port); | 729 | hash = sctp_ep_hashfn(ntohs(laddr->v4.sin_port)); |
730 | head = &sctp_ep_hashtable[hash]; | 730 | head = &sctp_ep_hashtable[hash]; |
731 | read_lock(&head->lock); | 731 | read_lock(&head->lock); |
732 | for (epb = head->chain; epb; epb = epb->next) { | 732 | for (epb = head->chain; epb; epb = epb->next) { |
@@ -830,7 +830,7 @@ static struct sctp_association *__sctp_lookup_association( | |||
830 | /* Optimize here for direct hit, only listening connections can | 830 | /* Optimize here for direct hit, only listening connections can |
831 | * have wildcards anyways. | 831 | * have wildcards anyways. |
832 | */ | 832 | */ |
833 | hash = sctp_assoc_hashfn(local->v4.sin_port, peer->v4.sin_port); | 833 | hash = sctp_assoc_hashfn(ntohs(local->v4.sin_port), ntohs(peer->v4.sin_port)); |
834 | head = &sctp_assoc_hashtable[hash]; | 834 | head = &sctp_assoc_hashtable[hash]; |
835 | read_lock(&head->lock); | 835 | read_lock(&head->lock); |
836 | for (epb = head->chain; epb; epb = epb->next) { | 836 | for (epb = head->chain; epb; epb = epb->next) { |
@@ -957,7 +957,7 @@ static struct sctp_association *__sctp_rcv_init_lookup(struct sk_buff *skb, | |||
957 | if (!af) | 957 | if (!af) |
958 | continue; | 958 | continue; |
959 | 959 | ||
960 | af->from_addr_param(paddr, params.addr, ntohs(sh->source), 0); | 960 | af->from_addr_param(paddr, params.addr, sh->source, 0); |
961 | 961 | ||
962 | asoc = __sctp_lookup_association(laddr, paddr, &transport); | 962 | asoc = __sctp_lookup_association(laddr, paddr, &transport); |
963 | if (asoc) | 963 | if (asoc) |