diff options
author | Sebastian Dröge <sebastian@centricular.com> | 2022-10-12 21:38:38 +0300 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2022-10-12 22:09:55 +0300 |
commit | 0a2e6e47c9dda4cca37f3a004e03f18ffa2ba3b7 (patch) | |
tree | 54efdc182177dc9e0f4b9ce714891c0badf7fa73 | |
parent | db8037d16cea67f028025c1b16d3975301d0c244 (diff) |
ndi: Silence some more clippy warnings
-rw-r--r-- | net/ndi/src/ndisink/imp.rs | 1 | ||||
-rw-r--r-- | net/ndi/src/ndisys.rs | 9 | ||||
-rw-r--r-- | net/ndi/src/receiver.rs | 2 |
3 files changed, 9 insertions, 3 deletions
diff --git a/net/ndi/src/ndisink/imp.rs b/net/ndi/src/ndisink/imp.rs index 24eb16947..cbf9a3e67 100644 --- a/net/ndi/src/ndisink/imp.rs +++ b/net/ndi/src/ndisink/imp.rs @@ -168,6 +168,7 @@ impl ElementImpl for NdiSink { PAD_TEMPLATES.as_ref() } + #[allow(clippy::single_match)] fn change_state( &self, transition: gst::StateChange, diff --git a/net/ndi/src/ndisys.rs b/net/ndi/src/ndisys.rs index b5c813fe3..4b062496b 100644 --- a/net/ndi/src/ndisys.rs +++ b/net/ndi/src/ndisys.rs @@ -1,6 +1,12 @@ // SPDX-License-Identifier: MPL-2.0 -#![allow(non_camel_case_types, non_upper_case_globals, non_snake_case)] +#![allow( + non_camel_case_types, + non_upper_case_globals, + non_snake_case, + clippy::upper_case_acronyms, + clippy::missing_safety_doc +)] #[cfg(unix)] use libloading::os::unix::{Library, Symbol}; @@ -16,6 +22,7 @@ const LIBRARY_NAME: &str = "libndi.so.5"; #[cfg(target_os = "macos")] const LIBRARY_NAME: &str = "libndi.dylib"; +#[allow(clippy::type_complexity)] struct FFI { _library: Library, initialize: Symbol<fn() -> bool>, diff --git a/net/ndi/src/receiver.rs b/net/ndi/src/receiver.rs index bf728e647..6c1298bae 100644 --- a/net/ndi/src/receiver.rs +++ b/net/ndi/src/receiver.rs @@ -1604,8 +1604,6 @@ impl Receiver { #[cfg(feature = "advanced-sdk")] if [NDIlib_FourCC_audio_type_AAC].contains(&fourcc) { - use std::convert::TryInto; - let compressed_packet = audio_frame.compressed_packet().ok_or_else(|| { error!( CAT, |