summaryrefslogtreecommitdiff
path: root/net/sctp/associola.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sctp/associola.c')
-rw-r--r--net/sctp/associola.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/net/sctp/associola.c b/net/sctp/associola.c
index 72199d14957..8d841f16dcb 100644
--- a/net/sctp/associola.c
+++ b/net/sctp/associola.c
@@ -930,6 +930,8 @@ struct sctp_transport *sctp_assoc_is_match(struct sctp_association *asoc,
const union sctp_addr *paddr)
{
struct sctp_transport *transport;
+ union sctp_addr tmp;
+ flip_to_n(&tmp, laddr);
sctp_read_lock(&asoc->base.addr_lock);
@@ -939,7 +941,7 @@ struct sctp_transport *sctp_assoc_is_match(struct sctp_association *asoc,
if (!transport)
goto out;
- if (sctp_bind_addr_match(&asoc->base.bind_addr, laddr,
+ if (sctp_bind_addr_match(&asoc->base.bind_addr, &tmp,
sctp_sk(asoc->base.sk)))
goto out;
}
@@ -1342,12 +1344,10 @@ int sctp_assoc_lookup_laddr(struct sctp_association *asoc,
const union sctp_addr *laddr)
{
int found;
- union sctp_addr tmp;
- flip_to_h(&tmp, laddr);
sctp_read_lock(&asoc->base.addr_lock);
if ((asoc->base.bind_addr.port == ntohs(laddr->v4.sin_port)) &&
- sctp_bind_addr_match(&asoc->base.bind_addr, &tmp,
+ sctp_bind_addr_match(&asoc->base.bind_addr, laddr,
sctp_sk(asoc->base.sk))) {
found = 1;
goto out;