From c483270f27de01944a62a413ec1b0c743f9f9e40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Tue, 9 Jul 2019 19:24:40 +0300 Subject: [PATCH] Never return gst::FlowError::CustomError outside the element It's for internal-usage and must be converted to a normal error at the boundary to the base classes. --- src/ndiaudiosrc.rs | 2 +- src/ndivideosrc.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ndiaudiosrc.rs b/src/ndiaudiosrc.rs index d52348c5..a669b206 100644 --- a/src/ndiaudiosrc.rs +++ b/src/ndiaudiosrc.rs @@ -462,7 +462,7 @@ impl BaseSrcImpl for NdiAudioSrc { continue; } gst_element_error!(element, gst::ResourceError::Read, ["NDI frame type none or error received, assuming that the source closed the stream...."]); - return Err(gst::FlowError::CustomError); + return Err(gst::FlowError::Error); } else if frame_type == NDIlib_frame_type_e::NDIlib_frame_type_none && _settings.loss_threshold == 0 { diff --git a/src/ndivideosrc.rs b/src/ndivideosrc.rs index 0b31b2f2..a24f4457 100644 --- a/src/ndivideosrc.rs +++ b/src/ndivideosrc.rs @@ -462,7 +462,7 @@ impl BaseSrcImpl for NdiVideoSrc { continue; } gst_element_error!(element, gst::ResourceError::Read, ["NDI frame type none or error received, assuming that the source closed the stream...."]); - return Err(gst::FlowError::CustomError); + return Err(gst::FlowError::Error); } else if frame_type == NDIlib_frame_type_e::NDIlib_frame_type_none && _settings.loss_threshold == 0 {