summaryrefslogtreecommitdiff
path: root/util-linux/mount.c
diff options
context:
space:
mode:
Diffstat (limited to 'util-linux/mount.c')
-rw-r--r--util-linux/mount.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c
index dd753235e..054db57b3 100644
--- a/util-linux/mount.c
+++ b/util-linux/mount.c
@@ -33,6 +33,11 @@
33#ifndef MS_SILENT 33#ifndef MS_SILENT
34#define MS_SILENT (1 << 15) 34#define MS_SILENT (1 << 15)
35#endif 35#endif
36/* Grab more as needed from util-linux's mount/mount_constants.h */
37#ifndef MS_DIRSYNC
38#define MS_DIRSYNC 128 /* Directory modifications are synchronous */
39#endif
40
36 41
37#if defined(__dietlibc__) 42#if defined(__dietlibc__)
38/* 16.12.2006, Sampo Kellomaki (sampo@iki.fi) 43/* 16.12.2006, Sampo Kellomaki (sampo@iki.fi)
@@ -122,6 +127,7 @@ static const int32_t mount_options[] = {
122 /* "exec" */ ~MS_NOEXEC, 127 /* "exec" */ ~MS_NOEXEC,
123 /* "noexec" */ MS_NOEXEC, 128 /* "noexec" */ MS_NOEXEC,
124 /* "sync" */ MS_SYNCHRONOUS, 129 /* "sync" */ MS_SYNCHRONOUS,
130 /* "dirsync" */ MS_DIRSYNC,
125 /* "async" */ ~MS_SYNCHRONOUS, 131 /* "async" */ ~MS_SYNCHRONOUS,
126 /* "atime" */ ~MS_NOATIME, 132 /* "atime" */ ~MS_NOATIME,
127 /* "noatime" */ MS_NOATIME, 133 /* "noatime" */ MS_NOATIME,
@@ -171,6 +177,7 @@ static const char mount_option_str[] =
171 "exec" "\0" 177 "exec" "\0"
172 "noexec" "\0" 178 "noexec" "\0"
173 "sync" "\0" 179 "sync" "\0"
180 "dirsync" "\0"
174 "async" "\0" 181 "async" "\0"
175 "atime" "\0" 182 "atime" "\0"
176 "noatime" "\0" 183 "noatime" "\0"
@@ -1665,6 +1672,8 @@ int mount_main(int argc, char **argv)
1665 SKIP_DESKTOP(const int nonroot = 0;) 1672 SKIP_DESKTOP(const int nonroot = 0;)
1666 USE_DESKTOP( int nonroot = (getuid() != 0);) 1673 USE_DESKTOP( int nonroot = (getuid() != 0);)
1667 1674
1675 sanitize_env_if_suid();
1676
1668 /* parse long options, like --bind and --move. Note that -o option 1677 /* parse long options, like --bind and --move. Note that -o option
1669 * and --option are synonymous. Yes, this means --remount,rw works. */ 1678 * and --option are synonymous. Yes, this means --remount,rw works. */
1670 1679