obs-browser
obs-browser copied to clipboard
obs-browser: Ensure saved source is alive
Description
In browser-client, created source is saved into two lists:
std::vector<obs_source_t*> audio_sources;
std::unordered_map<int, AudioStream> audio_streams;
But there is no reference for audio_sources.
I meet a crash as below:

Motivation and Context
How Has This Been Tested?
Types of changes
Checklist:
- [ ] My code has been run through clang-format.
- [ ] I have read the contributing document.
- [ ] My code is not on the master branch.
- [ ] The code has been tested.
- [ ] All commit messages are properly formatted and commits squashed where appropriate.
- [ ] I have included updates to all appropriate documentation.