diff options
Diffstat (limited to 'bridges')
-rw-r--r-- | bridges/bridge_softmix.c | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/bridges/bridge_softmix.c b/bridges/bridge_softmix.c index b35994895..2d71fc37c 100644 --- a/bridges/bridge_softmix.c +++ b/bridges/bridge_softmix.c @@ -786,17 +786,17 @@ static void softmix_bridge_leave(struct ast_bridge *bridge, struct ast_bridge_ch { struct softmix_channel *sc; struct softmix_bridge_data *softmix_data; + softmix_data = bridge->tech_pvt; sc = bridge_channel->tech_pvt; + if (!sc) { + return; + } if (bridge->softmix.video_mode.mode == AST_BRIDGE_VIDEO_MODE_SFU) { sfu_topologies_on_leave(bridge_channel, &bridge->channels); } - if (!sc) { - return; - } - if (bridge->softmix.binaural_active) { if (sc->binaural) { set_binaural_data_leave(&softmix_data->convolve, sc->binaural_pos, @@ -1060,14 +1060,10 @@ static int softmix_bridge_write(struct ast_bridge *bridge, struct ast_bridge_cha res = ast_bridge_queue_everyone_else(bridge, bridge_channel, frame); break; case AST_FRAME_VOICE: - if (bridge_channel) { - softmix_bridge_write_voice(bridge, bridge_channel, frame); - } + softmix_bridge_write_voice(bridge, bridge_channel, frame); break; case AST_FRAME_VIDEO: - if (bridge_channel) { - softmix_bridge_write_video(bridge, bridge_channel, frame); - } + softmix_bridge_write_video(bridge, bridge_channel, frame); break; case AST_FRAME_CONTROL: res = softmix_bridge_write_control(bridge, bridge_channel, frame); |