diff options
| author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2009-12-02 23:38:13 -0800 | 
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2009-12-02 23:38:13 -0800 | 
| commit | 467832032cc07626880363efa8625719c16c04eb (patch) | |
| tree | ee9a62c04f0b3106e412bc1b2dd1cea5566d5ca7 /net/sctp/sm_statefuns.c | |
| parent | 66d2a5952eab875f1286e04f738ef029afdaf013 (diff) | |
| parent | 22763c5cf3690a681551162c15d34d935308c8d7 (diff) | |
| download | olio-linux-3.10-467832032cc07626880363efa8625719c16c04eb.tar.xz olio-linux-3.10-467832032cc07626880363efa8625719c16c04eb.zip  | |
Merge commit 'v2.6.32' into next
Diffstat (limited to 'net/sctp/sm_statefuns.c')
| -rw-r--r-- | net/sctp/sm_statefuns.c | 15 | 
1 files changed, 9 insertions, 6 deletions
diff --git a/net/sctp/sm_statefuns.c b/net/sctp/sm_statefuns.c index c8fae1983dd..d4df45022ff 100644 --- a/net/sctp/sm_statefuns.c +++ b/net/sctp/sm_statefuns.c @@ -384,6 +384,11 @@ sctp_disposition_t sctp_sf_do_5_1B_init(const struct sctp_endpoint *ep,  	if (!new_asoc)  		goto nomem; +	if (sctp_assoc_set_bind_addr_from_ep(new_asoc, +					     sctp_scope(sctp_source(chunk)), +					     GFP_ATOMIC) < 0) +		goto nomem_init; +  	/* The call, sctp_process_init(), can fail on memory allocation.  */  	if (!sctp_process_init(new_asoc, chunk->chunk_hdr->type,  			       sctp_source(chunk), @@ -401,9 +406,6 @@ sctp_disposition_t sctp_sf_do_5_1B_init(const struct sctp_endpoint *ep,  		len = ntohs(err_chunk->chunk_hdr->length) -  			sizeof(sctp_chunkhdr_t); -	if (sctp_assoc_set_bind_addr_from_ep(new_asoc, GFP_ATOMIC) < 0) -		goto nomem_init; -  	repl = sctp_make_init_ack(new_asoc, chunk, GFP_ATOMIC, len);  	if (!repl)  		goto nomem_init; @@ -1452,6 +1454,10 @@ static sctp_disposition_t sctp_sf_do_unexpected_init(  	if (!new_asoc)  		goto nomem; +	if (sctp_assoc_set_bind_addr_from_ep(new_asoc, +				sctp_scope(sctp_source(chunk)), GFP_ATOMIC) < 0) +		goto nomem; +  	/* In the outbound INIT ACK the endpoint MUST copy its current  	 * Verification Tag and Peers Verification tag into a reserved  	 * place (local tie-tag and per tie-tag) within the state cookie. @@ -1488,9 +1494,6 @@ static sctp_disposition_t sctp_sf_do_unexpected_init(  			sizeof(sctp_chunkhdr_t);  	} -	if (sctp_assoc_set_bind_addr_from_ep(new_asoc, GFP_ATOMIC) < 0) -		goto nomem; -  	repl = sctp_make_init_ack(new_asoc, chunk, GFP_ATOMIC, len);  	if (!repl)  		goto nomem;  |