(c: &CStr)
| 434 | // Lazily compute and cache cert file/dir paths |
| 435 | static CERT_PATHS: LazyLock<(PathBuf, PathBuf)> = LazyLock::new(|| { |
| 436 | fn path_from_cstr(c: &CStr) -> PathBuf { |
| 437 | #[cfg(unix)] |
| 438 | { |
| 439 | use std::os::unix::ffi::OsStrExt; |
| 440 | std::ffi::OsStr::from_bytes(c.to_bytes()).into() |
| 441 | } |
| 442 | #[cfg(windows)] |
| 443 | { |
| 444 | // Use lossy conversion for potential non-UTF8 |
| 445 | PathBuf::from(c.to_string_lossy().as_ref()) |
| 446 | } |
| 447 | } |
| 448 | |
| 449 | let probe = probe(); |
| 450 | let cert_file = probe |
no test coverage detected