summaryrefslogtreecommitdiffstats
path: root/cli/src/cli-cmd-parser.c
diff options
context:
space:
mode:
authorAtin Mukherjee <amukherj@redhat.com>2015-04-16 17:45:04 +0530
committerKrishnan Parthasarathi <kparthas@redhat.com>2015-04-28 01:55:25 -0700
commit00a74ad99ec3ee2090aff0849ab95458941aaaec (patch)
tree7eb2620debc00f5f7187753240bf3a4b1e554925 /cli/src/cli-cmd-parser.c
parent3cce15950d6bdf426751f3b2dc91c72ba55cc036 (diff)
cli: fix vol_type in volume info xml
xml parsing of voltype should be inline with the cli Backport of http://review.gluster.org/10271 Change-Id: I41ddddac00d07f03b56a041e1c3f5a132fbd7393 BUG: 1215517 Signed-off-by: Atin Mukherjee <amukherj@redhat.com> Reviewed-on: http://review.gluster.org/10271 Tested-by: NetBSD Build System Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaushal M <kaushal@redhat.com> (cherry picked from commit 4c3724f195240e40994b71add255f85ee1b025fb) Reviewed-on: http://review.gluster.org/10396 Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Diffstat (limited to 'cli/src/cli-cmd-parser.c')
-rw-r--r--cli/src/cli-cmd-parser.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c
index a8e09a46631..e9c8dfa352c 100644
--- a/cli/src/cli-cmd-parser.c
+++ b/cli/src/cli-cmd-parser.c
@@ -372,6 +372,9 @@ cli_validate_disperse_volume (char *word, gf1_cluster_type type,
cli_err ("replicated-dispersed volume is not "
"supported");
goto out;
+ default:
+ cli_err ("Invalid type given");
+ break;
}
out:
return ret;
@@ -509,6 +512,9 @@ cli_cmd_volume_create_parse (struct cli_state *state, const char **words,
cli_err ("replicated-dispersed volume is not "
"supported");
goto out;
+ default:
+ cli_err ("Invalid type given");
+ goto out;
}
if (wordcount < (index+2)) {
@@ -567,6 +573,9 @@ cli_cmd_volume_create_parse (struct cli_state *state, const char **words,
cli_err ("striped-tier volume is not "
"supported");
goto out;
+ default:
+ cli_err ("Invalid type given");
+ goto out;
}
if (wordcount < (index + 2)) {
ret = -1;