Skip to content

[BUG]: Crash after minutes or hours of sucessfull audio / video streaming #1071

@AlexRadacki

Description

@AlexRadacki

Package version

3.0.0-pre.7

Environment

* OS: Windows11
* Unity version: Unity 2022.3.29f1

Steps To Reproduce

  1. Build and start "Receiver" with a custom TCP signalling server
  2. Build and start "Sender" (both will now auto call, add tracks, send offer + answer + connect using a valid ice candidate)
  3. Wait until the "Sender" app crashes.

Current Behavior

The "Sender" app crashes with the following:

========== OUTPUTTING STACK TRACE ==================

0x00007FFC66E8B915 (webrtc) PeerConnectionRegisterOnIceCandidate
0x00007FFC66E8D9DD (webrtc) PeerConnectionRegisterOnIceCandidate
0x00007FFC67A013BB (webrtc) UnityPluginUnload
0x00007FFC67A01209 (webrtc) UnityPluginUnload
0x00007FFC66F175D8 (webrtc) StatsGetTimestamp
0x00007FFC66F1706F (webrtc) StatsGetTimestamp
0x00007FFC67A09EAF (webrtc) UnityPluginUnload
0x00007FFC6724A59D (webrtc) PeerConnectionRegisterOnRemoveTrack
0x00007FFC672497C0 (webrtc) PeerConnectionRegisterOnRemoveTrack
0x00007FFC67248ACD (webrtc) PeerConnectionRegisterOnRemoveTrack
0x00007FFC6724160D (webrtc) PeerConnectionRegisterOnRemoveTrack
0x00007FFC66F01B67 (webrtc) StatsGetTimestamp
0x00007FFC66F97D8E (webrtc) StatsGetTimestamp
0x00007FFD744A259D (KERNEL32) BaseThreadInitThunk
0x00007FFD7592AF38 (ntdll) RtlUserThreadStart

========== END OF STACKTRACE ===========

Right before it crashes, one can hear the sender audio stream stopping for a split-second. It recovers and finally crashes after around one second.
It seems like the peer connection closes, tries to recover by creating a new one and ultimately crashes the app.

Expected Behavior

Stable audio / video streaming.

Anything else?

We're trying to use WebRTC to easily monitor and support multiple local VR instances using an operator station. For this we need 10-16 audio bidirectional streams as well as one video stream from the HMDs to the operator.

Our test consists of:

  • Unity app "Receiver" which accepts offers and creates the necessary UIs + audio mixer references. It also features a custom TCP signalling server.
  • Unity app "Sender" which creates the offer and accepts the answer
    Currently, we're testing on Windows, ultimately it needs to work on Win, iOS, Android.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions