Make SCTPtransport enter "closed" state when DTLStransport does.
Bug: webrtc:11090
Change-Id: I30e0b70387746d6c544ed1818f276569d4258cf4
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/159888
Reviewed-by: Emad Omara <emadomara@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29810}
diff --git a/pc/data_channel.cc b/pc/data_channel.cc
index c5a8aeb..e87bb85 100644
--- a/pc/data_channel.cc
+++ b/pc/data_channel.cc
@@ -359,9 +359,10 @@
}
}
-void DataChannel::OnTransportChannelDestroyed() {
- // The SctpTransport is going away (for example, because the SCTP m= section
- // was rejected), so we need to close abruptly.
+void DataChannel::OnTransportChannelClosed() {
+ // The SctpTransport is unusable (for example, because the SCTP m= section
+ // was rejected, or because the DTLS transport closed), so we need to close
+ // abruptly.
CloseAbruptly();
}