Skip to content

find: Fix -fstype with stacked mounts#532

Merged
sylvestre merged 1 commit intouutils:mainfrom
tavianator:fstype-stacked
Apr 24, 2025
Merged

find: Fix -fstype with stacked mounts#532
sylvestre merged 1 commit intouutils:mainfrom
tavianator:fstype-stacked

Conversation

@tavianator
Copy link
Copy Markdown
Contributor

If you stack two mounts on top of each other, e.g.

# mount -t ext4 /dev/sdX /mnt
# mount -t f2fs /dev/sdY /mnt

then read_fs_list() will return two entries for that mount point. The
later one is the one with the correct type, since the later mount is on
top of the earlier one.

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 8, 2025

Codecov Report

Attention: Patch coverage is 50.00000% with 2 lines in your changes missing coverage. Please review.

Project coverage is 87.37%. Comparing base (b94b5f0) to head (cd87902).
Report is 13 commits behind head on main.

Files with missing lines Patch % Lines
src/find/matchers/printf.rs 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #532      +/-   ##
==========================================
- Coverage   87.38%   87.37%   -0.02%     
==========================================
  Files          31       31              
  Lines        6824     6826       +2     
  Branches      321      321              
==========================================
+ Hits         5963     5964       +1     
- Misses        630      631       +1     
  Partials      231      231              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Crypto-Darth
Copy link
Copy Markdown
Contributor

image

Some minor clippy warnings here.

If you stack two mounts on top of each other, e.g.

    # mount -t ext4 /dev/sdX /mnt
    # mount -t f2fs /dev/sdY /mnt

then read_fs_list() will return two entries for that mount point.  The
later one is the one with the correct type, since the later mount is on
top of the earlier one.
@tavianator
Copy link
Copy Markdown
Contributor Author

@Crypto-Darth Thanks, fixed

@sylvestre sylvestre merged commit e5f7dae into uutils:main Apr 24, 2025
18 of 20 checks passed
@tavianator tavianator deleted the fstype-stacked branch April 24, 2025 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants