diff options
author | Rahul <rahul@gluster.com> | 2011-02-22 04:13:14 +0000 |
---|---|---|
committer | Anand V. Avati <avati@dev.gluster.com> | 2011-03-01 22:07:21 -0800 |
commit | 77d82df9d5e0047b0f1779130c4031cf3ce8ae1b (patch) | |
tree | 1d8ccf0e3d96537447489a85208f0534113eac0f /cli/src/cli-cmd-volume.c | |
parent | 5166c40af2502d1a26d4c0947378321b9bc3857c (diff) |
Display correct usage of rebalance command when it is wrongly entered.v3.1.3qa2
Signed-off-by: Rahul <rahul@gluster.com>
Signed-off-by: Anand V. Avati <avati@dev.gluster.com>
BUG: 1922 (Volume not present wrong message displayed on command line)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1922
Diffstat (limited to 'cli/src/cli-cmd-volume.c')
-rw-r--r-- | cli/src/cli-cmd-volume.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/cli/src/cli-cmd-volume.c b/cli/src/cli-cmd-volume.c index a790b326e83..8414a50b69c 100644 --- a/cli/src/cli-cmd-volume.c +++ b/cli/src/cli-cmd-volume.c @@ -482,6 +482,13 @@ cli_cmd_volume_defrag_cbk (struct cli_state *state, struct cli_cmd_word *word, goto out; } + if (strcmp (words[3], "start") && strcmp (words[3], "stop") && + strcmp (words[3], "status")) { + cli_usage_out (word->pattern); + parse_error = 1; + goto out; + } + ret = dict_set_str (dict, "volname", (char *)words[2]); if (ret) goto out; |