aboutsummaryrefslogtreecommitdiffstats
path: root/net/sctp/socket.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sctp/socket.c')
-rw-r--r--net/sctp/socket.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/net/sctp/socket.c b/net/sctp/socket.c
index 44f2acb3d433..6140471efd4b 100644
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
@@ -9225,6 +9225,16 @@ static int sctp_sock_migrate(struct sock *oldsk, struct sock *newsk,
9225 if (err) 9225 if (err)
9226 return err; 9226 return err;
9227 9227
9228 /* New ep's auth_hmacs should be set if old ep's is set, in case
9229 * that net->sctp.auth_enable has been changed to 0 by users and
9230 * new ep's auth_hmacs couldn't be set in sctp_endpoint_init().
9231 */
9232 if (oldsp->ep->auth_hmacs) {
9233 err = sctp_auth_init_hmacs(newsp->ep, GFP_KERNEL);
9234 if (err)
9235 return err;
9236 }
9237
9228 /* Move any messages in the old socket's receive queue that are for the 9238 /* Move any messages in the old socket's receive queue that are for the
9229 * peeled off association to the new socket's receive queue. 9239 * peeled off association to the new socket's receive queue.
9230 */ 9240 */