]> git.ipfire.org Git - thirdparty/asterisk.git/commit
core_unreal.c: Fix memory leak in ast_unreal_new_channels()
authorGeorge Joseph <gjoseph@sangoma.com>
Tue, 15 Oct 2024 17:11:28 +0000 (11:11 -0600)
committerGeorge Joseph <gjoseph@sangoma.com>
Thu, 17 Oct 2024 15:20:41 +0000 (15:20 +0000)
commit99350fd91c9810236464e176e6d3ee0ad0cf8e9a
tree0cef87f63d8846e705cec0542f58b39925c21edc
parentd2b16e57bfa89dac708bcc67a8451007ea5146d9
core_unreal.c: Fix memory leak in ast_unreal_new_channels()

When the channel tech is multistream capable, the reference to
chan_topology was passed to the new channel.  When the channel tech
isn't multistream capable, the reference to chan_topology was never
released.  "Local" channels are multistream capable so it didn't
affect them but the confbridge "CBAnn" and the bridge_media
"Recorder" channels are not so they caused a leak every time one
of them was created.

Also added tracing to ast_stream_topology_alloc() and
stream_topology_destroy() to assist with debugging.

Resolves: #938
main/core_unreal.c
main/stream.c