summaryrefslogtreecommitdiffstats
path: root/mdadm.c
diff options
context:
space:
mode:
authorNeil Brown <neilb@suse.de>2006-10-23 00:56:27 +0200
committerNeil Brown <neilb@suse.de>2006-10-23 00:56:27 +0200
commitcbfbcb0b503752a560e607039924f3192fde314b (patch)
tree9088c00bc03172599c0116f7d57aeabff2ecdcd0 /mdadm.c
parentIncrease default size of bitmap for v1 superblocks. (diff)
downloadmdadm-cbfbcb0b503752a560e607039924f3192fde314b.tar.xz
mdadm-cbfbcb0b503752a560e607039924f3192fde314b.zip
Improve error message when wrong --update option is given.
Diffstat (limited to 'mdadm.c')
-rw-r--r--mdadm.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/mdadm.c b/mdadm.c
index 00514a6e..41e6c4c5 100644
--- a/mdadm.c
+++ b/mdadm.c
@@ -596,7 +596,13 @@ int main(int argc, char *argv[])
continue;
}
- fprintf(stderr, Name ": '--update %s' invalid. Only 'sparc2.2', 'super-minor', 'uuid', 'resync' or 'summaries' supported\n",update);
+ if (strcmp(update,"?") == 0 || strcmp(update, "help") == 0)
+ fprintf(stderr, Name ": ");
+ else
+ fprintf(stderr, Name ": '--update=%s' is invalid. ", update);
+ fprintf(stderr, "Valid --update options are:\n"
+ " 'sparc2.2', 'super-minor', 'uuid', 'name', 'resync',\n"
+ " 'summaries', 'homehost', 'byteorder'.\n");
exit(2);
case O(ASSEMBLE,NoDegraded): /* --no-degraded */