diff options
author | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2001-04-01 16:01:11 +0000 |
---|---|---|
committer | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2001-04-01 16:01:11 +0000 |
commit | a4e240b392b5901b9ac42f6f7ee6a1c49c494520 (patch) | |
tree | c661196acbb1adfa81257a7f23b08bd15d653be8 /util-linux | |
parent | c612c4a23f6f69f1d7c692f5ad84f66298171a4c (diff) | |
download | busybox-w32-a4e240b392b5901b9ac42f6f7ee6a1c49c494520.tar.gz busybox-w32-a4e240b392b5901b9ac42f6f7ee6a1c49c494520.tar.bz2 busybox-w32-a4e240b392b5901b9ac42f6f7ee6a1c49c494520.zip |
Move the mtab support stuff into libbb
-Erik
git-svn-id: svn://busybox.net/trunk/busybox@2229 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'util-linux')
-rw-r--r-- | util-linux/mount.c | 4 | ||||
-rw-r--r-- | util-linux/umount.c | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c index 9f7ac43c1..57dc73e55 100644 --- a/util-linux/mount.c +++ b/util-linux/mount.c | |||
@@ -160,7 +160,7 @@ do_mount(char *specialfile, char *dir, char *filesystemtype, | |||
160 | /* If the mount was sucessful, do anything needed, then return TRUE */ | 160 | /* If the mount was sucessful, do anything needed, then return TRUE */ |
161 | if (status == 0 || fakeIt==TRUE) { | 161 | if (status == 0 || fakeIt==TRUE) { |
162 | 162 | ||
163 | #if defined BB_MTAB | 163 | #if defined BB_FEATURE_MTAB_SUPPORT |
164 | if (useMtab == TRUE) { | 164 | if (useMtab == TRUE) { |
165 | erase_mtab(specialfile); // Clean any stale entries | 165 | erase_mtab(specialfile); // Clean any stale entries |
166 | write_mtab(specialfile, dir, filesystemtype, flags, mtab_opts); | 166 | write_mtab(specialfile, dir, filesystemtype, flags, mtab_opts); |
@@ -385,7 +385,7 @@ extern int mount_main(int argc, char **argv) | |||
385 | case 'f': | 385 | case 'f': |
386 | fakeIt = TRUE; | 386 | fakeIt = TRUE; |
387 | break; | 387 | break; |
388 | #ifdef BB_MTAB | 388 | #ifdef BB_FEATURE_MTAB_SUPPORT |
389 | case 'n': | 389 | case 'n': |
390 | useMtab = FALSE; | 390 | useMtab = FALSE; |
391 | break; | 391 | break; |
diff --git a/util-linux/umount.c b/util-linux/umount.c index cc7d38d7c..3e23b9705 100644 --- a/util-linux/umount.c +++ b/util-linux/umount.c | |||
@@ -57,7 +57,7 @@ static int doForce = FALSE; | |||
57 | #if defined BB_FEATURE_MOUNT_LOOP | 57 | #if defined BB_FEATURE_MOUNT_LOOP |
58 | static int freeLoop = TRUE; | 58 | static int freeLoop = TRUE; |
59 | #endif | 59 | #endif |
60 | #if defined BB_MTAB | 60 | #if defined BB_FEATURE_MTAB_SUPPORT |
61 | static int useMtab = TRUE; | 61 | static int useMtab = TRUE; |
62 | #endif | 62 | #endif |
63 | static int umountAll = FALSE; | 63 | static int umountAll = FALSE; |
@@ -106,7 +106,7 @@ char *mtab_getinfo(const char *match, const char which) | |||
106 | if (which == MTAB_GETMOUNTPT) { | 106 | if (which == MTAB_GETMOUNTPT) { |
107 | return cur->mountpt; | 107 | return cur->mountpt; |
108 | } else { | 108 | } else { |
109 | #if !defined BB_MTAB | 109 | #if !defined BB_FEATURE_MTAB_SUPPORT |
110 | if (strcmp(cur->device, "/dev/root") == 0) { | 110 | if (strcmp(cur->device, "/dev/root") == 0) { |
111 | /* Adjusts device to be the real root device, | 111 | /* Adjusts device to be the real root device, |
112 | * or leaves device alone if it can't find it */ | 112 | * or leaves device alone if it can't find it */ |
@@ -197,7 +197,7 @@ static int do_umount(const char *name) | |||
197 | } | 197 | } |
198 | } | 198 | } |
199 | if (status == 0) { | 199 | if (status == 0) { |
200 | #if defined BB_MTAB | 200 | #if defined BB_FEATURE_MTAB_SUPPORT |
201 | if (useMtab == TRUE) | 201 | if (useMtab == TRUE) |
202 | erase_mtab(name); | 202 | erase_mtab(name); |
203 | #endif | 203 | #endif |
@@ -255,7 +255,7 @@ extern int umount_main(int argc, char **argv) | |||
255 | freeLoop = FALSE; | 255 | freeLoop = FALSE; |
256 | break; | 256 | break; |
257 | #endif | 257 | #endif |
258 | #ifdef BB_MTAB | 258 | #ifdef BB_FEATURE_MTAB_SUPPORT |
259 | case 'n': | 259 | case 'n': |
260 | useMtab = FALSE; | 260 | useMtab = FALSE; |
261 | break; | 261 | break; |