()
| 108 | #[test] |
| 109 | #[cfg(all(unix, not(target_arch = "wasm32")))] |
| 110 | fn mlock_graceful_on_linux() { |
| 111 | // mlock with a stack pointer that may or may not succeed depending on |
| 112 | // RLIMIT_MEMLOCK. Either way we must not panic. |
| 113 | let mut buf = [0u8; 32]; |
| 114 | mlock_best_effort(buf.as_mut_ptr() as *mut libc::c_void, 32); |
| 115 | munlock_best_effort(buf.as_mut_ptr() as *mut libc::c_void, 32); |
| 116 | // Success = no panic. |
| 117 | } |
| 118 | } |
nothing calls this directly
no test coverage detected