Disable Trickle ICE

This commit is contained in:
Alexandre Iooss 2020-10-14 18:37:51 +02:00
parent 7d8c16fbb7
commit 099fb8e203
No known key found for this signature in database
GPG Key ID: 6C79278F3FCDCC02
1 changed files with 5 additions and 1 deletions

View File

@ -154,12 +154,16 @@ func newPeerHandler(localSdpChan chan webrtc.SessionDescription, remoteSdp struc
return
}
// Sets the LocalDescription, and starts our UDP listeners
// Sets the LocalDescription
// Using GatheringCompletePromise disable trickle ICE
// FIXME: https://github.com/pion/webrtc/wiki/Release-WebRTC@v3.0.0
gatherComplete := webrtc.GatheringCompletePromise(peerConnection)
if err = peerConnection.SetLocalDescription(answer); err != nil {
log.Println("Failed to set local description", err)
localSdpChan <- webrtc.SessionDescription{}
return
}
<-gatherComplete
// Send answer to client
localSdpChan <- answer