Commit 9494c7c5 authored by Wei Yongjun's avatar Wei Yongjun Committed by David S. Miller

sctp: fix oops while removed transport still using as retran path

Since we can not update retran path to unconfirmed transports,
when we remove a peer, the retran path may not be update if the
other transports are all unconfirmed, and we will still using
the removed transport as the retran path. This may cause panic
if retrasnmit happen.
Signed-off-by: default avatarWei Yongjun <yjwei@cn.fujitsu.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 25f7bf7d
...@@ -569,6 +569,8 @@ void sctp_assoc_rm_peer(struct sctp_association *asoc, ...@@ -569,6 +569,8 @@ void sctp_assoc_rm_peer(struct sctp_association *asoc,
sctp_assoc_set_primary(asoc, transport); sctp_assoc_set_primary(asoc, transport);
if (asoc->peer.active_path == peer) if (asoc->peer.active_path == peer)
asoc->peer.active_path = transport; asoc->peer.active_path = transport;
if (asoc->peer.retran_path == peer)
asoc->peer.retran_path = transport;
if (asoc->peer.last_data_from == peer) if (asoc->peer.last_data_from == peer)
asoc->peer.last_data_from = transport; asoc->peer.last_data_from = transport;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment