mirror of
https://github.com/troglobit/finit.git
synced 2026-10-15 10:29:35 +00:00
Warn if Finit fail to mount /proc and /sys
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
1 parent
d7da177742
commit
2094d2a53a
1 file changed
+4
-2
+4
-2
@@ -345,8 +345,10 @@ int main(int argc, char* argv[])
|
||||
*/
|
||||
chdir("/");
|
||||
umask(0);
|
||||
mount("none", "/proc", "proc", 0, NULL);
|
||||
mount("none", "/sys", "sysfs", 0, NULL);
|
||||
if (mount("none", "/proc", "proc", 0, NULL))
|
||||
_pe("Failed mounting /proc");
|
||||
if (mount("none", "/sys", "sysfs", 0, NULL))
|
||||
_pe("Failed mounting /sysfs");
|
||||
if (fisdir("/proc/bus/usb"))
|
||||
mount("none", "/proc/bus/usb", "usbfs", 0, NULL);
|
||||
|
||||
|
||||
Reference in new issue
Block a user