]> git.pld-linux.org Git - packages/util-linux.git/blame - util-linux-2.12q-more-fake-checks-v2.patch
- use functions
[packages/util-linux.git] / util-linux-2.12q-more-fake-checks-v2.patch
CommitLineData
a160d850
ER
1> Running `mount -fv /mnt/pnt` incorrectly updates /etc/mtab
2
3This one is bogus.
4
5Manpage:
6
7=====
8-f Causes everything to be done except for the actual system call;
9 if it's not obvious, this ``fakes'' mounting the file system. This option
10 is useful in conjunction with the -v flag to determine what the mount
11 command is trying to do. It can also be used to add entries for devices that
12 were mounted earlier with the -n option.
13=====
14
15Also, we need it in /etc/init.d/checkroot to regen /etc/mtab ...
16
17
18=======================================================================
19Running `mount -afvt type` incorrectly warns that 'nothing was mounted'
20
21--- mount/mount.c
22+++ mount/mount.c
23#@@ -659,7 +659,7 @@
24# if (verbose)
25# print_one (&mnt);
26#
27#- if (!nomtab && mtab_is_writable()) {
28#+ if (!fake && !nomtab && mtab_is_writable()) {
29# if (flags & MS_REMOUNT)
30# update_mtab (mnt.mnt_dir, &mnt);
31# else {
32@@ -1629,7 +1629,7 @@
33 case 0:
34 /* mount -a */
35 result = do_mount_all (types, options, test_opts);
36- if (result == 0 && verbose)
37+ if (result == 0 && verbose && !fake)
38 error(_("nothing was mounted"));
39 break;
40
This page took 0.030433 seconds and 4 git commands to generate.