Skip to content

Commit

Permalink
Add missing documentation for mnt::fuse3::Mount
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Carl Jones <[email protected]>
  • Loading branch information
dannycjones committed Nov 6, 2024
1 parent 29eb586 commit 3787523
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/mnt/fuse3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,17 @@ fn ensure_last_os_error() -> io::Error {
}
}

/// An active FUSE mount.
///
/// This struct manages the lifecycle of the mount, unmounting and destroying the session when dropped.
#[derive(Debug)]
pub struct Mount {
fuse_session: *mut c_void,
}
impl Mount {
/// Mounts the filesystem at the given path, with the given options.
///
/// Returns the mounted FUSE file descriptor along with a [Mount] for handling the mount lifecycle.
pub fn new(mnt: &Path, options: &[MountOption]) -> io::Result<(Arc<File>, Mount)> {
let mnt = CString::new(mnt.as_os_str().as_bytes()).unwrap();
with_fuse_args(options, |args| {
Expand Down

0 comments on commit 3787523

Please sign in to comment.