After 8 years, we resolved the memory leak issue in SRS using our own implementation of basic Smart Pointers, maintaining the project's manageability.
Introduction
Each stream on the SRS server has a Source object that manages the stream's lifecycle. To keep the logic and code simple, SRS did not release the Source object; with a large number of streams, such as constantly changing streaming addresses, this led to continuous memory growth and leaks.