Closed Jonbeckas closed 8 months ago
Thanks for your contribution, @Jonbeckas! Please make sure you sign our CLA, as it's a required step before we can merge this.
I haven't investigated the issue yet, but I don't think this is a proper fix. Resetting a PeerConnection state in the Janus core is not simply a matter of clearing a flag: there are steps that must be traversed. If you're not getting the PC closed, then maybe the plugin is not closing the PC, so it's the SIP plugin that should be updated, not the core.
I don't think it is possible to fix this only in the sip_plugin, because the hangup event is not fired, because the session still has the flag JANUS_ICE_HANDLE_WEBRTC_ALERT
when no sdp was send yet.
It's possible to fix it just in the sip_plugin if we set session->establishing
to 0 on decline, but it would be a duplication with the later called hangup function.
Structural not compleatly clean, but it should fix issue #3332