Skip to content

Commit

Permalink
Remove incorrect mount API
Browse files Browse the repository at this point in the history
Signed-off-by: Alex Saveau <[email protected]>
  • Loading branch information
SUPERCILEX committed Aug 15, 2024
1 parent 2293963 commit 15f07af
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/mount/mount_unmount.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,18 +19,18 @@ pub fn mount<Source: path::Arg, Target: path::Arg, Fs: path::Arg, Data: path::Ar
target: Target,
file_system_type: Fs,
flags: MountFlags,
data: Data,
data: impl Into<Option<Data>>,
) -> io::Result<()> {
source.into_with_c_str(|source| {
target.into_with_c_str(|target| {
file_system_type.into_with_c_str(|file_system_type| {
data.into_with_c_str(|data| {
option_into_with_c_str(data.into(), |data| {
backend::mount::syscalls::mount(
Some(source),
target,
Some(file_system_type),
MountFlagsArg(flags.bits()),
Some(data),
data,
)
})
})
Expand All @@ -49,6 +49,8 @@ pub fn mount<Source: path::Arg, Target: path::Arg, Fs: path::Arg, Data: path::Ar
///
/// [Linux]: https://man7.org/linux/man-pages/man2/mount.2.html
#[inline]
#[deprecated(note = "This API was added in error, use the expressive mount APIs instead.")]
#[doc(hidden)]
pub fn mount2<Source: path::Arg, Target: path::Arg, Fs: path::Arg>(
source: Option<Source>,
target: Target,
Expand Down

0 comments on commit 15f07af

Please sign in to comment.