aboutsummaryrefslogtreecommitdiff
path: root/util-linux/mount.c
diff options
context:
space:
mode:
Diffstat (limited to 'util-linux/mount.c')
-rw-r--r--util-linux/mount.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c
index 4d5c2243a..b8dd8a925 100644
--- a/util-linux/mount.c
+++ b/util-linux/mount.c
@@ -2205,10 +2205,14 @@ int mount_main(int argc UNUSED_PARAM, char **argv)
2205 2205
2206 // Parse remaining options 2206 // Parse remaining options
2207 // Max 2 params; -o is a list, -v is a counter 2207 // Max 2 params; -o is a list, -v is a counter
2208 opt_complementary = "?2" IF_FEATURE_MOUNT_VERBOSE("vv"); 2208 opt = getopt32(argv, "^"
2209 opt = getopt32(argv, OPTION_STR, &lst_o, &fstype, &O_optmatch 2209 OPTION_STR
2210 IF_FEATURE_MOUNT_OTHERTAB(, &fstabname) 2210 "\0" "?2"IF_FEATURE_MOUNT_VERBOSE("vv"),
2211 IF_FEATURE_MOUNT_VERBOSE(, &verbose)); 2211 &lst_o, &fstype, &O_optmatch
2212 IF_FEATURE_MOUNT_OTHERTAB(, &fstabname)
2213 IF_FEATURE_MOUNT_VERBOSE(, &verbose)
2214 );
2215
2212 while (lst_o) append_mount_options(&cmdopts, llist_pop(&lst_o)); // -o 2216 while (lst_o) append_mount_options(&cmdopts, llist_pop(&lst_o)); // -o
2213 if (opt & OPT_r) append_mount_options(&cmdopts, "ro"); // -r 2217 if (opt & OPT_r) append_mount_options(&cmdopts, "ro"); // -r
2214 if (opt & OPT_w) append_mount_options(&cmdopts, "rw"); // -w 2218 if (opt & OPT_w) append_mount_options(&cmdopts, "rw"); // -w