]> Git Repo - linux.git/blobdiff - net/sctp/associola.c
sctp: release cached route when the transport goes down.
[linux.git] / net / sctp / associola.c
index 525864bf4f07d6caef08520d195053d5b0e25edf..215b56951d76bde24512c87f8c50f01814e7ad49 100644 (file)
@@ -810,11 +810,16 @@ void sctp_assoc_control_transport(struct sctp_association *asoc,
                break;
 
        case SCTP_TRANSPORT_DOWN:
-               /* if the transort was never confirmed, do not transition it
-                * to inactive state.
+               /* If the transport was never confirmed, do not transition it
+                * to inactive state.  Also, release the cached route since
+                * there may be a better route next time.
                 */
                if (transport->state != SCTP_UNCONFIRMED)
                        transport->state = SCTP_INACTIVE;
+               else {
+                       dst_release(transport->dst);
+                       transport->dst = NULL;
+               }
 
                spc_state = SCTP_ADDR_UNREACHABLE;
                break;
This page took 0.030898 seconds and 4 git commands to generate.