From 0aaa630c217f8035d47fff59b181d9f5a6965751 Mon Sep 17 00:00:00 2001 From: phk Date: Mon, 21 Oct 2002 21:41:19 +0000 Subject: DEVFS has been nmountified, so use nmount(2) to mount it. --- usr.sbin/sade/install.c | 16 ++++++++++++++-- usr.sbin/sysinstall/install.c | 16 ++++++++++++++-- 2 files changed, 28 insertions(+), 4 deletions(-) (limited to 'usr.sbin') diff --git a/usr.sbin/sade/install.c b/usr.sbin/sade/install.c index 8cfc955..3756905 100644 --- a/usr.sbin/sade/install.c +++ b/usr.sbin/sade/install.c @@ -41,6 +41,7 @@ #include #include #include +#include #include #define MSDOSFS #include @@ -1008,8 +1009,19 @@ installFilesystems(dialogMenuItem *self) /* Mount devfs for other partitions to mount */ Mkdir("/mnt/dev"); - if (!Fake) - mountfailed = mount("devfs", "/mnt/dev", 0, NULL); + if (!Fake) { + struct iovec iov[4]; + + iov[0].iov_base = "fstype"; + iov[0].iov_len = strlen(iov[0].iov_base) + 1; + iov[1].iov_base = "devfs"; + iov[1].iov_len = strlen(iov[1].iov_base) + 1; + iov[2].iov_base = "fspath"; + iov[1].iov_len = strlen(iov[2].iov_base) + 1; + iov[3].iov_base = "/mnt/dev"; + iov[1].iov_len = strlen(iov[3].iov_base) + 1; + mountfailed = nmount(iov, 4, 0); + } if (mountfailed) { dialog_clear_norefresh(); diff --git a/usr.sbin/sysinstall/install.c b/usr.sbin/sysinstall/install.c index 8cfc955..3756905 100644 --- a/usr.sbin/sysinstall/install.c +++ b/usr.sbin/sysinstall/install.c @@ -41,6 +41,7 @@ #include #include #include +#include #include #define MSDOSFS #include @@ -1008,8 +1009,19 @@ installFilesystems(dialogMenuItem *self) /* Mount devfs for other partitions to mount */ Mkdir("/mnt/dev"); - if (!Fake) - mountfailed = mount("devfs", "/mnt/dev", 0, NULL); + if (!Fake) { + struct iovec iov[4]; + + iov[0].iov_base = "fstype"; + iov[0].iov_len = strlen(iov[0].iov_base) + 1; + iov[1].iov_base = "devfs"; + iov[1].iov_len = strlen(iov[1].iov_base) + 1; + iov[2].iov_base = "fspath"; + iov[1].iov_len = strlen(iov[2].iov_base) + 1; + iov[3].iov_base = "/mnt/dev"; + iov[1].iov_len = strlen(iov[3].iov_base) + 1; + mountfailed = nmount(iov, 4, 0); + } if (mountfailed) { dialog_clear_norefresh(); -- cgit v1.1