Skip to content

Commit 37a6cc3

Browse files
committed
Just wait for 3 seconds for ice gathering.
1 parent 46f74b0 commit 37a6cc3

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

lib/src/rtc_session.dart

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1635,7 +1635,14 @@ class RTCSession extends EventManager {
16351635
if (candidate != null) {
16361636
this.emit(EventIceCandidate(candidate, ready));
16371637
if (!finished) {
1638-
//ready();
1638+
finished = true;
1639+
/**
1640+
* Just wait for 3 seconds. In the case of multiple network connections,
1641+
* the RTCIceGatheringStateComplete event needs to wait for 10 ~ 30 seconds.
1642+
* Because trickle ICE is not defined in the sip protocol, the delay of
1643+
* initiating a call to answer the call waiting will be unacceptable.
1644+
*/
1645+
setTimeout(() => ready(), 3000);
16391646
}
16401647
}
16411648
};

0 commit comments

Comments
 (0)