-
Notifications
You must be signed in to change notification settings - Fork 743
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
INVITE without SDP and 200/ACK retransmission produces "Called in wrong state: STATE_INPROGRESS" #367
Comments
Also, in the above scenario, JsSIP does not send BYE (which it should). |
The problem is here: case JsSIP_C.ACK:
if(this.status === C.STATUS_WAITING_FOR_ACK) {
clearTimeout(this.timers.ackTimer);
clearTimeout(this.timers.invite2xxTimer);
if (this.late_sdp) {
if (!request.body) {
ended.call(this, 'remote', request, JsSIP_C.causes.MISSING_SDP);
break;
}
this.connection.setRemoteDescription(
new rtcninja.RTCSessionDescription({type:'answer', sdp:request.body}),
// success
function() {
self.status = C.STATUS_CONFIRMED;
},
// failure
function() {
ended.call(self, 'remote', request, JsSIP_C.causes.BAD_MEDIA_DESCRIPTION);
}
);
}
else {
this.status = C.STATUS_CONFIRMED;
}
if (this.status === C.STATUS_CONFIRMED && !this.is_confirmed) {
confirmed.call(this, 'remote', request);
}
}
break; When the first ACK with SDP answer is received, @jmillan may update Thoughts? P.S. I don't understand yet why no BYE is generated. |
ACK retransmissions are now properly handled (7790ffd). However since BYE is not sent I leave the issue open. To be clear: If somehow the ACK processing fails, no BYE is sent (unless I'm missing something). |
@ibc, you're right. We were emitting the
|
Yep! Thanks. 0.7.22 published. |
Scenario:
ef2fAgent.js:48667 rtcninja:ERROR:RTCPeerConnection setRemoteDescription() | error: +0ms Failed to set remote answer sdp: Called in wrong state: STATE_INPROGRESS
Basically we must prevent that a retransmission of the ACK (with SDP answer in this scenario) breaks the underlying PeerConnection state.
The text was updated successfully, but these errors were encountered: