After updating firefox to the last version (40), my WebRTC code stopped working when video wasn't available in firefox. After digging up a bit, I saw that videoTrack's lenght is 1, even when video is not being sent.
This function is placed in peerconnectionclient.js:
peerConnectionClient.prototype.onSetRemoteDescriptionSuccess_ = function() {
var remoteStreams = this.pc_.getRemoteStreams();
if (this.onremotesdpset) {
this.onremotesdpset(remoteStreams.length > 0 && remoteStreams[0].getVideoTracks().length > 0);
}
};
Before firefox 40, remoteStreams[0].getVideoTracks().length was 0, when the remote client was not sending video. Now, videotracks lenght is 1.
What is more, videoTrack's readyState value is ="mute", which was removed from the specifications a while ago. Is this a bug? If so,how can I fix this? I have read an article that could be related with this issue https://hacks.mozilla.org/category/webrtc/as/complete/