From: ericm Date: Sat, 18 Jul 2009 00:04:43 +0000 (+0000) Subject: branch: HEAD X-Git-Tag: v1_9_230~56 X-Git-Url: https://git.whamcloud.com/gitweb?a=commitdiff_plain;h=229a0272b072c3f9d47660a013d7b63cfe5db11d;p=fs%2Flustre-release.git branch: HEAD mount.lustre don't filter out option "mgssec". b=19413 r=fanyong r=yujian --- diff --git a/lustre/utils/mount_lustre.c b/lustre/utils/mount_lustre.c index bbbe9ef..52b9989 100644 --- a/lustre/utils/mount_lustre.c +++ b/lustre/utils/mount_lustre.c @@ -266,6 +266,13 @@ static int parse_one_option(const char *check, int *flagp) return 0; } +static void append_option(char *options, const char *one) +{ + if (*options) + strcat(options, ","); + strcat(options, one); +} + /* Replace options with subset of Lustre-specific options, and fill in mount flags */ int parse_options(char *orig_options, int *flagp) @@ -293,6 +300,8 @@ int parse_options(char *orig_options, int *flagp) retry = MAX_RETRIES; else if (retry < 0) retry = 0; + } else if (strncmp(arg, "mgssec", 6) == 0) { + append_option(options, opt); } } else if (strncmp(opt, "force", 5) == 0) { //XXX special check for 'force' option @@ -300,9 +309,7 @@ int parse_options(char *orig_options, int *flagp) printf("force: %d\n", force); } else if (parse_one_option(opt, flagp) == 0) { /* pass this on as an option */ - if (*options) - strcat(options, ","); - strcat(options, opt); + append_option(options, opt); } } strcpy(orig_options, options);