From 37071c9d601f5f01c7cb4760ad81d228649fa90e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Tue, 28 May 2019 04:35:12 +0200 Subject: [PATCH] gstreamer: Fix build with serde feature enabled --- gstreamer/src/sample_serde.rs | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/gstreamer/src/sample_serde.rs b/gstreamer/src/sample_serde.rs index 54b23f3d8..1fe5953ef 100644 --- a/gstreamer/src/sample_serde.rs +++ b/gstreamer/src/sample_serde.rs @@ -49,18 +49,15 @@ impl From for Sample { fn from(mut buf_de: SampleDe) -> Self { if buf_de.buffer.is_some() { Sample::new::( - buf_de.buffer.as_ref().map(|buffer| buffer.as_ref()), - buf_de.caps.as_ref().map(|caps| caps.as_ref()), + buf_de.buffer.as_ref(), + buf_de.caps.as_ref(), buf_de.segment.as_ref(), buf_de.info.take(), ) } else { Sample::with_buffer_list::( - buf_de - .buffer_list - .as_ref() - .map(|buffer_list| buffer_list.as_ref()), - buf_de.caps.as_ref().map(|caps| caps.as_ref()), + buf_de.buffer_list.as_ref(), + buf_de.caps.as_ref(), buf_de.segment.as_ref(), buf_de.info.take(), )