summaryrefslogtreecommitdiff
path: root/util-linux/mount.c
diff options
context:
space:
mode:
authorRob Landley2006-04-04 16:56:04 +0000
committerRob Landley2006-04-04 16:56:04 +0000
commitab8736064b0220c0b7dd3d4226c3f40976a31c53 (patch)
tree9eeb51c1e63754c589ea0cd4c9f17194d94b7593 /util-linux/mount.c
parent3b84dfc2a833a1a78030be332080461dbdce88df (diff)
downloadbusybox-ab8736064b0220c0b7dd3d4226c3f40976a31c53.zip
busybox-ab8736064b0220c0b7dd3d4226c3f40976a31c53.tar.gz
You'd think there'd be a compiler warning for "pointless if", wouldn't you?
Diffstat (limited to 'util-linux/mount.c')
-rw-r--r--util-linux/mount.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c
index 42d0eb2..ba55d24 100644
--- a/util-linux/mount.c
+++ b/util-linux/mount.c
@@ -291,11 +291,11 @@ static int singlemount(struct mntent *mp)
}
}
- // Look at the file. (Not found isn't a failure for remount.)
+ // Look at the file. (Not found isn't a failure for remount, or for
+ // a synthetic filesystem like proc or sysfs.)
if (lstat(mp->mnt_fsname, &st));
-
- if (!(vfsflags & (MS_REMOUNT | MS_BIND | MS_MOVE))) {
+ else if (!(vfsflags & (MS_REMOUNT | MS_BIND | MS_MOVE))) {
// Do we need to allocate a loopback device for it?
if (ENABLE_FEATURE_MOUNT_LOOP && S_ISREG(st.st_mode)) {