Skip to content

statfs type mismatch #27

@diyorbekibragimov

Description

@diyorbekibragimov

Following the steps outlined in the README to install the project, when I run
cargo build --release

What I get is:
error[E0308]: arguments to this method are incorrect --> src/fs.rs:1875:27 | 1875 | reply.statfs( | ^^^^^^ 1876 | stat.blocks(), | ------------- expected u64, found u321877 | stat.blocks_free(), | ------------------ expectedu64, found u321878 | stat.blocks_available(), | ----------------------- expectedu64, found u321879 | stat.files(), | ------------ expectedu64, found u321880 | stat.files_free(), | ----------------- expectedu64, found u32``

Then the compiler suggests a fix
359 | pub fn statfs( | ^^^^^^ help: you can convert a u32to au64| 1876 | stat.blocks().into(), | +++++++ help: you can convert au32to au64| 1877 | stat.blocks_free().into(), | +++++++ help: you can convert au32to au64| 1878 | stat.blocks_available().into(), | +++++++ help: you can convert au32to au64| 1879 | stat.files().into(), | +++++++ help: you can convert au32to au64 | 1880 | stat.files_free().into(),

So, by simply adding .into() to the five input variables in reply.statfs, it works.

Environment

  • OS: macOS (Apple Silicon)
  • Rust: rustc 1.95.0 (59807616e 2026-04-14)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions