livesync: Log a category error when we are missing the segment

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1387>
This commit is contained in:
Jan Alexander Steffens (heftig) 2023-10-25 00:20:12 +02:00 committed by Sebastian Dröge
parent ab84da6d32
commit 274e3cd71b

View file

@ -898,7 +898,10 @@ impl LiveSync {
}
// At this stage we should really really have a segment
let segment = state.in_segment.as_ref().ok_or(gst::FlowError::Error)?;
let segment = state.in_segment.as_ref().ok_or_else(|| {
gst::error!(CAT, imp: self, "Missing segment");
gst::FlowError::Error
})?;
if state.single_segment {
let dts = segment