Open skndi opened 2 months ago
When a viewer disconnection is detected the stream is closed immediately instead of waiting for a reconnection.
The session should not be destructed before ICE_CONNECTION_STATE_FAILED is reached.
https://gist.github.com/skndi/95bb6a5548905fecd0de9ea7745e0742
The behavior seems to come from this line https://github.com/awslabs/amazon-kinesis-video-streams-webrtc-sdk-c/blob/8248241cec28b651839d91f77a706f4fd028dbeb/samples/Common.c#L84 I think the session should be marked for termination only if the new state is RTC_PEER_CONNECTION_STATE_FAILED or RTC_PEER_CONNECTION_STATE_FAILED.
1.10.2
gcc 10.2
Embedded Linux
Ambarella CV2 chip, aarch64
Please confirm you have already done the following
Describe the bug
When a viewer disconnection is detected the stream is closed immediately instead of waiting for a reconnection.
Expected Behavior
The session should not be destructed before ICE_CONNECTION_STATE_FAILED is reached.
Current Behavior
https://gist.github.com/skndi/95bb6a5548905fecd0de9ea7745e0742
The behavior seems to come from this line https://github.com/awslabs/amazon-kinesis-video-streams-webrtc-sdk-c/blob/8248241cec28b651839d91f77a706f4fd028dbeb/samples/Common.c#L84 I think the session should be marked for termination only if the new state is RTC_PEER_CONNECTION_STATE_FAILED or RTC_PEER_CONNECTION_STATE_FAILED.
Reproduction Steps
WebRTC C SDK version being used
1.10.2
Compiler and Version used
gcc 10.2
Operating System and version
Embedded Linux
Platform being used
Ambarella CV2 chip, aarch64