Close previous request channels when during initial retry (#1409)

So we don't leave abandoned requests hanging on the media instance
This commit is contained in:
David Zhao
2023-02-09 17:27:33 -08:00
committed by GitHub
parent aebec26ace
commit 9a7ea7a2fa
5 changed files with 143 additions and 0 deletions
+8
View File
@@ -129,6 +129,10 @@ func (s *RTCNodeSink) Close() {
}
}
func (s *RTCNodeSink) IsClosed() bool {
return s.isClosed.Load()
}
func (s *RTCNodeSink) OnClose(f func()) {
s.onClose = f
}
@@ -166,6 +170,10 @@ func (s *SignalNodeSink) Close() {
}
}
func (s *SignalNodeSink) IsClosed() bool {
return s.isClosed.Load()
}
func (s *SignalNodeSink) OnClose(f func()) {
s.onClose = f
}