mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2024-11-25 13:01:07 +00:00
fallbacksrc: Flush source before restarting on errors
It might still be blocked downstream for a while, e.g. in the clocksync. Flushing does not cause any problems as fallbackswitch is not going to forward it and will only unblock everything up to there.
This commit is contained in:
parent
e973d41bac
commit
4a54001aed
1 changed files with 3 additions and 0 deletions
|
@ -2107,6 +2107,9 @@ impl FallbackSrc {
|
||||||
}
|
}
|
||||||
drop(state_guard);
|
drop(state_guard);
|
||||||
|
|
||||||
|
gst::debug!(CAT, obj: element, "Flushing source");
|
||||||
|
let _ = source.send_event(gst::event::FlushStart::builder().build());
|
||||||
|
|
||||||
gst::debug!(CAT, obj: element, "Shutting down source");
|
gst::debug!(CAT, obj: element, "Shutting down source");
|
||||||
let _ = source.set_state(gst::State::Null);
|
let _ = source.set_state(gst::State::Null);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue