Skip to content

Commit a19577c

Browse files
committed
Suppress null pointer deref warnings
This is a known issue with bindgen under heavy discussion, but doesn't look like it will be resolved soon. This attribute suppresses genuine warnings about undefined behavior in a pattern generated by bindgen many, many times. It should be removed when the bindgen issue is resolved. Until then, it obscures other helpful warnings and errors. See: rust-lang/rust-bindgen#1651 Signed-off-by: Keith Koskie <[email protected]>
1 parent d5e1992 commit a19577c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

cryptoki-sys/src/lib.rs

+4
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@
88
#![allow(clippy::string_lit_as_bytes)]
99
// Public items exportedby this crate should match the C style
1010
#![allow(clippy::upper_case_acronyms)]
11+
// Suppress warnings from bindgen-generated code
12+
// Remove on resolution of
13+
// https://github.com/rust-lang/rust-bindgen/issues/1651
14+
#![allow(deref_nullptr)]
1115

1216
// For supported targets: use the generated and committed bindings.
1317
#[cfg(all(

0 commit comments

Comments
 (0)