summaryrefslogtreecommitdiff
path: root/util-linux/mount.c
diff options
context:
space:
mode:
authorDenis Vlasenko2006-09-10 18:38:17 +0000
committerDenis Vlasenko2006-09-10 18:38:17 +0000
commit39e93cc95148536eb42b577980f912cbe3888a9b (patch)
tree7f077cca5f48c852e639c166bbe3501ddd4db708 /util-linux/mount.c
parent2244a21a8e11736516caf6b239ae108768f9390d (diff)
downloadbusybox-39e93cc95148536eb42b577980f912cbe3888a9b.zip
busybox-39e93cc95148536eb42b577980f912cbe3888a9b.tar.gz
nfsmount: nfsmount.h merged into nfsmount.c
Diffstat (limited to 'util-linux/mount.c')
-rw-r--r--util-linux/mount.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c
index e76c7db..b1d9e28 100644
--- a/util-linux/mount.c
+++ b/util-linux/mount.c
@@ -92,9 +92,9 @@ struct {
static void append_mount_options(char **oldopts, char *newopts)
{
if(*oldopts && **oldopts) {
- char *temp=xasprintf("%s,%s",*oldopts,newopts);
+ char *temp = xasprintf("%s,%s",*oldopts,newopts);
free(*oldopts);
- *oldopts=temp;
+ *oldopts = temp;
} else {
if (ENABLE_FEATURE_CLEAN_UP) free(*oldopts);
*oldopts = xstrdup(newopts);
@@ -346,13 +346,14 @@ static int singlemount(struct mntent *mp, int ignore_busy)
default:
bb_error_msg( errno == EPERM || errno == EACCES
? bb_msg_perm_denied_are_you_root
- : "Couldn't setup loop device");
+ : "cannot setup loop device");
return errno;
}
// Autodetect bind mounts
- } else if (S_ISDIR(st.st_mode) && !mp->mnt_type) vfsflags |= MS_BIND;
+ } else if (S_ISDIR(st.st_mode) && !mp->mnt_type)
+ vfsflags |= MS_BIND;
}
/* If we know the fstype (or don't need to), jump straight
@@ -399,7 +400,7 @@ report_error:
if (rc && errno == EBUSY && ignore_busy) rc = 0;
if (rc < 0)
- bb_perror_msg("Mounting %s on %s failed", mp->mnt_fsname, mp->mnt_dir);
+ bb_perror_msg("mounting %s on %s failed", mp->mnt_fsname, mp->mnt_dir);
return rc;
}
@@ -466,7 +467,7 @@ int mount_main(int argc, char **argv)
if (!all) {
FILE *mountTable = setmntent(bb_path_mtab_file, "r");
- if(!mountTable) bb_error_msg_and_die("No %s",bb_path_mtab_file);
+ if(!mountTable) bb_error_msg_and_die("no %s",bb_path_mtab_file);
while (getmntent_r(mountTable,mtpair,bb_common_bufsiz1,
sizeof(bb_common_bufsiz1)))
@@ -514,7 +515,7 @@ int mount_main(int argc, char **argv)
else fstabname="/etc/fstab";
if (!(fstab=setmntent(fstabname,"r")))
- bb_perror_msg_and_die("Cannot read %s",fstabname);
+ bb_perror_msg_and_die("cannot read %s",fstabname);
// Loop through entries until we find what we're looking for.
@@ -535,7 +536,7 @@ int mount_main(int argc, char **argv)
// If we didn't find anything, complain.
if (!mtnext->mnt_fsname)
- bb_error_msg_and_die("Can't find %s in %s",
+ bb_error_msg_and_die("can't find %s in %s",
argv[optind], fstabname);
// Mount the last thing we found.