File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -2099,7 +2099,6 @@ func (pc *PeerConnection) close(shouldGracefullyClose bool) error {
2099
2099
}
2100
2100
if shouldGracefullyClose && ! alreadyGracefullyClosed {
2101
2101
defer close (pc .isGracefulClosedDone )
2102
- pc .ops .GracefulClose ()
2103
2102
}
2104
2103
2105
2104
// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-close (step #3)
@@ -2156,6 +2155,8 @@ func (pc *PeerConnection) close(shouldGracefullyClose bool) error {
2156
2155
pc .updateConnectionState (pc .ICEConnectionState (), pc .dtlsTransport .State ())
2157
2156
2158
2157
if shouldGracefullyClose {
2158
+ pc .ops .GracefulClose ()
2159
+
2159
2160
// note that it isn't canon to stop gracefully
2160
2161
pc .sctpTransport .lock .Lock ()
2161
2162
for _ , d := range pc .sctpTransport .dataChannels {
You can’t perform that action at this time.
0 commit comments