Skip to content

Commit

Permalink
add_mountpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
n01e0 committed Nov 6, 2020
1 parent 223925e commit bf1c947
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/high_level.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ impl Fanotify {
fanotify_mark(self.fd, FAN_MARK_ADD, mode, AT_FDCWD, path)?;
Ok(())
}
pub fn add_mountpoint<P: ?Sized + FanotifyPath>(&self, mode: u64, path: &P) -> Result<(), Error> {
fanotify_mark(self.fd, FAN_MARK_ADD | FAN_MARK_MOUNT, mode, AT_FDCWD, path)?;
Ok(())
}
pub fn remove_path<P: ?Sized + FanotifyPath>(&self, mode: u64, path: &P) -> Result<(), Error> {
fanotify_mark(self.fd, FAN_MARK_REMOVE, mode, AT_FDCWD, path)?;
Ok(())
Expand Down

0 comments on commit bf1c947

Please sign in to comment.