ubase/linux/umount.c

18 lines
345 B
C
Raw Normal View History

/* See LICENSE file for copyright and license details. */
2013-08-07 08:52:10 +00:00
#include <sys/mount.h>
#include <stdio.h>
#include "../ubase.h"
#include "../util.h"
int
do_umount(const char *target, int opts)
{
int flags = 0;
if (opts & UBASE_MNT_FORCE)
flags |= MNT_FORCE;
if (opts & UBASE_MNT_DETACH)
flags |= MNT_DETACH;
2013-08-07 08:52:10 +00:00
return umount2(target, flags);
}