Skip to content

Commit 9d6865a

Browse files
committed
make volume_status_dirty public
so it can be also used outside of tests
1 parent 2fd18cb commit 9d6865a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/fat/fat_table.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ impl<'a> FatTable<'a> {
2626
const FAT16_DIRTY_BIT: u16 = 15;
2727
const FAT32_DIRTY_BIT: u32 = 27;
2828

29-
#[cfg(test)]
3029
pub(crate) fn dirty(&self) -> bool {
3130
match self.fat_type {
3231
FatType::Fat16 => {

src/volume_mgr.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -394,8 +394,9 @@ where
394394
}
395395
Ok(())
396396
}
397-
#[cfg(test)]
398-
fn volume_status_dirty(&self, volume: &FatVolume) -> Result<bool, Error<D::Error>> {
397+
398+
/// Checking if the volume is dirty or was unmounted correctly in a previous usage
399+
pub fn volume_status_dirty(&self, volume: &FatVolume) -> Result<bool, Error<D::Error>> {
399400
let mut blocks = [Block::new()];
400401
let fat_table1_start = volume.lba_start + volume.fat_start;
401402
self.block_device

0 commit comments

Comments
 (0)