mirror of
https://github.com/troglobit/finit.git
synced 2026-10-01 21:42:40 +07:00
Mount /dev as tmpfs before creating directories inside
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
This commit is contained in:
+3
-3
@@ -302,6 +302,9 @@ int main()
|
||||
#endif
|
||||
umask(0);
|
||||
|
||||
if (mountdev)
|
||||
mount("none", "/dev", "tmpfs", 0, "mode=0755");
|
||||
|
||||
#ifdef MAKE_DEVICES
|
||||
mkdir("/dev/shm", 0755);
|
||||
mkdir("/dev/pts", 0755);
|
||||
@@ -316,9 +319,6 @@ int main()
|
||||
mount("none", "/proc/bus/usb", "usbfs", 0, NULL);
|
||||
mount(SYSROOT, "/", NULL, MS_MOVE, NULL);
|
||||
|
||||
if (mountdev)
|
||||
mount("none", "/dev", "tmpfs", 0, "mode=0755");
|
||||
|
||||
#ifdef MAKE_DEVICES
|
||||
mkdir("/dev/input", 0755);
|
||||
chardev("/dev/urandom", 0666, 1, 9);
|
||||
|
||||
Reference in New Issue
Block a user