From 6849e4b4c34987d6c12f89a62bf95ee4deb109bb Mon Sep 17 00:00:00 2001 From: Arun Raghavan Date: Wed, 11 Sep 2024 14:11:31 -0400 Subject: [PATCH] gstreamer: Use new pad probe take_*() API in tests Part-of: --- gstreamer/src/pad.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gstreamer/src/pad.rs b/gstreamer/src/pad.rs index 05418f318..b4509397e 100644 --- a/gstreamer/src/pad.rs +++ b/gstreamer/src/pad.rs @@ -2451,7 +2451,7 @@ mod tests { { let events = events.clone(); pad.add_probe(crate::PadProbeType::EVENT_UPSTREAM, move |_, info| { - if let Some(PadProbeData::Event(event)) = info.data.take() { + if let Some(event) = info.take_event() { let mut events = events.lock().unwrap(); events.push(event); } else { @@ -2464,7 +2464,7 @@ mod tests { { let buffers = buffers.clone(); pad.add_probe(crate::PadProbeType::BUFFER, move |_, info| { - if let Some(PadProbeData::Buffer(buffer)) = info.data.take() { + if let Some(buffer) = info.take_buffer() { let mut buffers = buffers.lock().unwrap(); info.flow_res = if buffers.is_empty() { Ok(FlowSuccess::Ok)