diff options
author | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2001-02-01 22:43:49 +0000 |
---|---|---|
committer | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2001-02-01 22:43:49 +0000 |
commit | a773090651a1d7b61974fbd637826668e7061449 (patch) | |
tree | 47dca5ab2df8982ea929c902216bca6bf9c31f44 /mtab.c | |
parent | deaca5da3373819de42ee9204f93fa8cfa3f48a5 (diff) | |
download | busybox-w32-a773090651a1d7b61974fbd637826668e7061449.tar.gz busybox-w32-a773090651a1d7b61974fbd637826668e7061449.tar.bz2 busybox-w32-a773090651a1d7b61974fbd637826668e7061449.zip |
Apply a patch from Larry Doolittle to add "-all" and "-none" switches
to multibuild.pl. I did a little formatting adjustments to make it
_very_ obvious when things stop working. I also removed the USE_PROCFS
config option -- just do the right thing when USE_DEVPS_PATCH is enabled.
-Erik
git-svn-id: svn://busybox.net/trunk/busybox@1739 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'mtab.c')
-rw-r--r-- | mtab.c | 10 |
1 files changed, 2 insertions, 8 deletions
@@ -21,12 +21,8 @@ void erase_mtab(const char *name) | |||
21 | 21 | ||
22 | /* Check if reading the mtab file failed */ | 22 | /* Check if reading the mtab file failed */ |
23 | if (mountTable == 0 | 23 | if (mountTable == 0 |
24 | #if ! defined BB_FEATURE_USE_PROCFS | 24 | /* Bummer. fall back on trying the /proc filesystem */ |
25 | ) { | 25 | && (mountTable = setmntent("/proc/mounts", "r")) == 0) { |
26 | #else | ||
27 | /* Bummer. fall back on trying the /proc filesystem */ | ||
28 | && (mountTable = setmntent("/proc/mounts", "r")) == 0) { | ||
29 | #endif | ||
30 | perror_msg("%s", mtab_file); | 26 | perror_msg("%s", mtab_file); |
31 | return; | 27 | return; |
32 | } | 28 | } |
@@ -74,14 +70,12 @@ void write_mtab(char *blockDevice, char *directory, | |||
74 | if (length > 1 && directory[length - 1] == '/') | 70 | if (length > 1 && directory[length - 1] == '/') |
75 | directory[length - 1] = '\0'; | 71 | directory[length - 1] = '\0'; |
76 | 72 | ||
77 | #ifdef BB_FEATURE_USE_PROCFS | ||
78 | if (filesystemType == 0) { | 73 | if (filesystemType == 0) { |
79 | struct mntent *p = find_mount_point(blockDevice, "/proc/mounts"); | 74 | struct mntent *p = find_mount_point(blockDevice, "/proc/mounts"); |
80 | 75 | ||
81 | if (p && p->mnt_type) | 76 | if (p && p->mnt_type) |
82 | filesystemType = p->mnt_type; | 77 | filesystemType = p->mnt_type; |
83 | } | 78 | } |
84 | #endif | ||
85 | m.mnt_fsname = blockDevice; | 79 | m.mnt_fsname = blockDevice; |
86 | m.mnt_dir = directory; | 80 | m.mnt_dir = directory; |
87 | m.mnt_type = filesystemType ? filesystemType : "default"; | 81 | m.mnt_type = filesystemType ? filesystemType : "default"; |