Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
Mario Danic 2018-01-17 09:35:27 +01:00
parent af95d66583
commit 11e03fb535

View file

@ -125,14 +125,12 @@ public class MagicPeerConnectionWrapper {
}
public void addCandidate(IceCandidate iceCandidate) {
if (peerConnection != null) {
if (peerConnection.getRemoteDescription() != null) {
if (peerConnection != null && peerConnection.getRemoteDescription() != null) {
peerConnection.addIceCandidate(iceCandidate);
} else {
iceCandidates.add(iceCandidate);
}
}
}
public void sendChannelData(DataChannelMessage dataChannelMessage) {
ByteBuffer buffer = null;