diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2006-11-20 20:09:01 -0500 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2006-12-03 00:26:42 -0500 |
commit | f235fca389f23cd6c9e0f466611bb2d6a05ae758 (patch) | |
tree | 7a08efd99e531d4b0d2db4e2ef188a116e0fbb44 /net | |
parent | e2fccedb0136205d02e97a41851503e2b96d2a17 (diff) |
[SCTP]: sctp_init_addrs() switched to net-endian.
Caller adjusted.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/sctp/input.c | 2 | ||||
-rw-r--r-- | net/sctp/sm_make_chunk.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/net/sctp/input.c b/net/sctp/input.c index 85b3441c4a23..0e5ac5e42c96 100644 --- a/net/sctp/input.c +++ b/net/sctp/input.c | |||
@@ -245,7 +245,7 @@ int sctp_rcv(struct sk_buff *skb) | |||
245 | chunk->sctp_hdr = sh; | 245 | chunk->sctp_hdr = sh; |
246 | 246 | ||
247 | /* Set the source and destination addresses of the incoming chunk. */ | 247 | /* Set the source and destination addresses of the incoming chunk. */ |
248 | sctp_init_addrs(chunk, &src, &dest); | 248 | sctp_init_addrs(chunk, &tmp2, &tmp); |
249 | 249 | ||
250 | /* Remember where we came from. */ | 250 | /* Remember where we came from. */ |
251 | chunk->transport = transport; | 251 | chunk->transport = transport; |
diff --git a/net/sctp/sm_make_chunk.c b/net/sctp/sm_make_chunk.c index cb8cecd85a2e..b5d4a61ed7a7 100644 --- a/net/sctp/sm_make_chunk.c +++ b/net/sctp/sm_make_chunk.c | |||
@@ -1031,9 +1031,9 @@ nodata: | |||
1031 | void sctp_init_addrs(struct sctp_chunk *chunk, union sctp_addr *src, | 1031 | void sctp_init_addrs(struct sctp_chunk *chunk, union sctp_addr *src, |
1032 | union sctp_addr *dest) | 1032 | union sctp_addr *dest) |
1033 | { | 1033 | { |
1034 | memcpy(&chunk->source_h, src, sizeof(union sctp_addr)); | 1034 | memcpy(&chunk->source, src, sizeof(union sctp_addr)); |
1035 | flip_to_n(&chunk->source, &chunk->source_h); | 1035 | flip_to_h(&chunk->source_h, &chunk->source); |
1036 | memcpy(&chunk->dest, dest, sizeof(union sctp_addr)); | 1036 | flip_to_h(&chunk->dest, dest); |
1037 | } | 1037 | } |
1038 | 1038 | ||
1039 | /* Extract the source address from a chunk. */ | 1039 | /* Extract the source address from a chunk. */ |