mirror of
https://github.com/pion/webrtc.git
synced 2025-10-04 23:02:48 +08:00
Fix deprecation cutover, and bad SDP creation
Methods that were marked as deprecated weren't properly handled. There was a mix of old+new ones supported which caused broken behavior. SDP creation didn't add SCTP to Offer Resolves #156
This commit is contained in:
@@ -61,7 +61,7 @@ func main() {
|
||||
datachannels := make([]*webrtc.RTCDataChannel, 0)
|
||||
var dataChannelsLock sync.RWMutex
|
||||
|
||||
peerConnection.Ondatachannel = func(d *webrtc.RTCDataChannel) {
|
||||
peerConnection.OnDataChannel = func(d *webrtc.RTCDataChannel) {
|
||||
dataChannelsLock.Lock()
|
||||
datachannels = append(datachannels, d)
|
||||
dataChannelsLock.Unlock()
|
||||
|
Reference in New Issue
Block a user