[BusyBox] mount -a, using sysfs()

Glenn McGrath bug1 at optushome.com.au
Thu Mar 1 10:51:37 UTC 2001


crap, wrong file, this is one that looks better.

Sorry for all the noise, ill shut up now.


Glenn
-------------- next part --------------
Common subdirectories: busybox.orig/CVS and busybox/CVS
Common subdirectories: busybox.orig/CVSROOT and busybox/CVSROOT
Binary files busybox.orig/busybox and busybox/busybox differ
Common subdirectories: busybox.orig/debian and busybox/debian
Common subdirectories: busybox.orig/docs and busybox/docs
Common subdirectories: busybox.orig/kernel-patches and busybox/kernel-patches
diff -U 3 busybox.orig/mount.c busybox/mount.c
--- busybox.orig/mount.c	Thu Mar  1 18:55:49 2001
+++ busybox/mount.c	Thu Mar  1 21:42:30 2001
@@ -246,11 +246,17 @@
 
 		while(i < num_of_filesystems) {
 			sysfs(2, i++, filesystemType);
-			status = do_mount(blockDevice, directory, filesystemType,
+			if ((strcmp(filesystemType, "tmpfs") != 0) &&
+				(strcmp(filesystemType, "shm") != 0) &&
+				(strcmp(filesystemType, "proc") != 0) &&
+				(strcmp(filesystemType, "ramfs") != 0) &&
+				(strcmp(filesystemType, "devpts") != 0)) {
+				status = do_mount(blockDevice, directory, filesystemType,
 					flags | MS_MGC_VAL, string_flags,
 					useMtab, fakeIt, mtab_opts);
-			if (status == TRUE)
-				break;
+				if (status == TRUE)
+					break;
+			}
 		}
 	} else {
 		status = do_mount(blockDevice, directory, filesystemType,
Common subdirectories: busybox.orig/pwd_grp and busybox/pwd_grp
Common subdirectories: busybox.orig/scripts and busybox/scripts
Common subdirectories: busybox.orig/tests and busybox/tests


More information about the busybox mailing list