summaryrefslogtreecommitdiffstats
path: root/ReadMe.c
diff options
context:
space:
mode:
authorDoug Ledford <dledford@redhat.com>2007-07-09 09:59:59 +1000
committerNeil Brown <neilb@suse.de>2007-07-09 09:59:59 +1000
commit024768c465668a23db794b000e6e0f476beeb0af (patch)
treeb5664a5184945c870a24188bed8311864a6cda02 /ReadMe.c
parente4dc510628a8c2d7b92c8ed537987716175a23a2 (diff)
downloadmdadm-024768c465668a23db794b000e6e0f476beeb0af.tar.gz
mdadm-024768c465668a23db794b000e6e0f476beeb0af.tar.xz
mdadm-024768c465668a23db794b000e6e0f476beeb0af.zip
Fix parsing of "-a" in various contexts.
From: Doug Ledford <dledford@redhat.com> This one fixes a bug where once manage mode is set, the -a short option is no longer parsed correctly (true of grow mode as well). This happens because when you switch the short opts to the bitmap_auto version, it specifies that the argument must follow a, yet the loop expects to get an undecorated option and parse it as the disk dev instead of trying to parse optarg. So, create a new short opt array that is used for manage and grow that doesn't list a as having an argument.
Diffstat (limited to 'ReadMe.c')
-rw-r--r--ReadMe.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/ReadMe.c b/ReadMe.c
index 9423db3..201651e 100644
--- a/ReadMe.c
+++ b/ReadMe.c
@@ -87,6 +87,8 @@ char Version[] = Name " - v2.6.2 - 21st May 2007\n";
*/
char short_options[]="-ABCDEFGIQhVXWvqbc:i:l:p:m:n:x:u:c:d:z:U:sarfRSow1tye:";
+char short_bitmap_options[]=
+ "-ABCDEFGIQhVXWvqb:c:i:l:p:m:n:x:u:c:d:z:U:sarfRSow1tye:";
char short_bitmap_auto_options[]=
"-ABCDEFGIQhVXWvqb:c:i:l:p:m:n:x:u:c:d:z:U:sa:rfRSow1tye:";