OSDN Git Service
(root)
/
uclinux-h8
/
uClibc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
13284bb
)
When there is no umount syscall, but umount2 is available, then
author
Eric Andersen
<andersen@codepoet.org>
Sun, 23 Jan 2005 11:27:02 +0000
(11:27 -0000)
committer
Eric Andersen
<andersen@codepoet.org>
Sun, 23 Jan 2005 11:27:02 +0000
(11:27 -0000)
try to emulate umount() using umount2()
libc/sysdeps/linux/common/umount.c
patch
|
blob
|
history
diff --git
a/libc/sysdeps/linux/common/umount.c
b/libc/sysdeps/linux/common/umount.c
index
6457ddf
..
f4eb8c6
100644
(file)
--- a/
libc/sysdeps/linux/common/umount.c
+++ b/
libc/sysdeps/linux/common/umount.c
@@
-12,6
+12,13
@@
#ifdef __NR_umount /* Some newer archs only have umount2 */
#include <sys/mount.h>
_syscall1(int, umount, const char *, specialfile);
+#elif defined __NR_umount2
+/* No umount syscall, but umount2 is available.... Try to
+ * emulate umount() using umount2() */
+int umount(const char *special_file, int flags)
+{
+ return _syscall2(int, umount2, const char *, special_file, int, flags);
+}
#else
int umount(const char *special_file)
{