瀏覽代碼

Per http://bugs.uclibc.org/view.php?id=12:
Some newer archs only have umount2

Eric Andersen 20 年之前
父節點
當前提交
a9c5c662d4
共有 1 個文件被更改,包括 10 次插入0 次删除
  1. 10 0
      libc/sysdeps/linux/common/umount.c

+ 10 - 0
libc/sysdeps/linux/common/umount.c

@@ -8,5 +8,15 @@
  */
 
 #include "syscalls.h"
+
+#ifdef __NR_umount	/* Some newer archs only have umount2 */
 #include <sys/mount.h>
 _syscall1(int, umount, const char *, specialfile);
+#else
+int umount(const char *special_file)
+{
+	__set_errno(ENOSYS);
+	return -1;
+}
+#endif
+