From 50eeb2f16dfa4342d50086404da068f5426cbe3c Mon Sep 17 00:00:00 2001 From: Marvin W Date: Wed, 9 Apr 2025 20:02:55 +0200 Subject: RTP: Tear down most of GStreamer while not in a call. This includes #1679 and works around an upstream bug in pipewire causing #1685 --- plugins/rtp/src/stream.vala | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'plugins/rtp/src/stream.vala') diff --git a/plugins/rtp/src/stream.vala b/plugins/rtp/src/stream.vala index 94549856..aa2b080d 100644 --- a/plugins/rtp/src/stream.vala +++ b/plugins/rtp/src/stream.vala @@ -454,7 +454,8 @@ public class Dino.Plugins.Rtp.Stream : Xmpp.Xep.JingleRtp.Stream { } send_rtp.set_locked_state(true); send_rtp.set_state(Gst.State.NULL); - pipe.remove(send_rtp); + // This happens async, so pipe might be gone by now. + if (pipe != null) pipe.remove(send_rtp); send_rtp = null; debug("Stopped sending RTP for %u", rtpid); } @@ -462,7 +463,8 @@ public class Dino.Plugins.Rtp.Stream : Xmpp.Xep.JingleRtp.Stream { private void on_send_rtcp_eos() { send_rtcp.set_locked_state(true); send_rtcp.set_state(Gst.State.NULL); - pipe.remove(send_rtcp); + // This happens async, so pipe might be gone by now. + if (pipe != null) pipe.remove(send_rtcp); send_rtcp = null; debug("Stopped sending RTCP for %u", rtpid); } -- cgit v1.3