diff --git a/src/scsi/linux.rs b/src/scsi/linux.rs index 539343d..772f80e 100644 --- a/src/scsi/linux.rs +++ b/src/scsi/linux.rs @@ -64,9 +64,9 @@ const _: () = assert!(std::mem::size_of::() == 88); const _: () = assert!(std::mem::size_of::() == 64); pub struct SgIoTransport { - fd: i32, + pub fd: i32, device_path: std::path::PathBuf, - fd_recovery: std::sync::Arc, + pub fd_recovery: std::sync::Arc, } impl SgIoTransport { diff --git a/src/scsi/mod.rs b/src/scsi/mod.rs index 0d5c142..d2250c1 100644 --- a/src/scsi/mod.rs +++ b/src/scsi/mod.rs @@ -6,7 +6,7 @@ //! - `windows.rs` — SPTI (SCSI Pass-Through Interface) #[cfg(target_os = "linux")] -pub(crate) mod linux; +pub mod linux; #[cfg(target_os = "macos")] mod macos; #[cfg(target_os = "windows")] diff --git a/tests/scsi_recovery.rs b/tests/scsi_recovery.rs index 747669e..e225970 100644 --- a/tests/scsi_recovery.rs +++ b/tests/scsi_recovery.rs @@ -39,7 +39,7 @@ fn test_sgio_transport_timeout_does_not_kill_transport() { assert!(result.is_err(), "expected Err on timeout, got {:?}", result); let err = result.unwrap_err(); assert!( - matches!(&err, libfreemkv::Error::ScsiError { status, .. } if *status == SCSI_STATUS_TRANSPORT_FAILURE), + matches!(&err, libfreemkv::Error::ScsiError { ref status, .. } if *status == SCSI_STATUS_TRANSPORT_FAILURE), "expected ScsiError(TRANSPORT_FAILURE), got {:?}", err );