Unity-Technologies / Unity-Technologies/com.unity.webrtc
[BUG]: Memory leak when using AddTrack/RemoveTrack repeatedly on Linux like Ubuntu20.02
Open
@karasusan is already working on this.
Since Jul 5, 2022.
bug
issued
- Dominant language
- Assembly
- Stars
- 852
- Forks
- 238
- PR merge metrics
- No merged PRs in 30d
Description
Package version
2.4.0-exp.8
Environment
* OS: Ubuntu20.04
* Unity version:2021.3
* GraphicsDevice: GLCore, Vulkan
Steps To Reproduce
- Create standalone build using sample project on Linux machine.
- Run the executable file and watch memory usage.
- Open MediaStream sample on the menu.
- Repeat push AddTrack button and RemoveTrack button
- You can see the memory usage increase rapidly.

Current Behavior
It increases the memory usage 50 - 100 MiB per once. Additionally, not release even if back to Menu scene from MediaStream scene.
Expected Behavior
The memory should not be increased.
Anything else?
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.