From 9498fe86b727a76edb1a1ffe74b0b6f12fabf640 Mon Sep 17 00:00:00 2001 From: CharleyWangZJU <57120416+CharleyWangZJU@users.noreply.github.com> Date: Wed, 6 Nov 2019 21:14:08 +0800 Subject: [PATCH] suggest to add default iceServers There is a bug. I open https://192.168.84.99:3004/ in firefox firstly, then open https://192.168.84.99:3004/ in my safari V12.0. Found that I cann't see firefox user in safari, but I can see safari user in firefox. When I add this iceServer, they can see both. --- src/sdk/conference/channel.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/sdk/conference/channel.js b/src/sdk/conference/channel.js index cd41f1a1..96a9862d 100644 --- a/src/sdk/conference/channel.js +++ b/src/sdk/conference/channel.js @@ -590,6 +590,7 @@ export class ConferencePeerConnectionChannel extends EventDispatcher { if (Utils.isChrome()) { pcConfiguration.sdpSemantics = 'unified-plan'; } + pcConfiguration.iceServers = pcConfiguration.iceServers || [{urls: "stun:stun.l.google.com:19302"}]; this._pc = new RTCPeerConnection(pcConfiguration); this._pc.onicecandidate = (event) => { this._onLocalIceCandidate.apply(this, [event]);