summaryrefslogtreecommitdiffstats
path: root/cli/src
diff options
context:
space:
mode:
authorKaushik BV <kaushikbv@gluster.com>2011-04-17 10:46:06 +0000
committerAnand Avati <avati@gluster.com>2011-04-17 21:40:59 -0700
commit4b813b3d14476a5cf6a3a54c32c2939a31fe9ba9 (patch)
treeff5d4181a8aa6d736cadf004f24ea791621e4de4 /cli/src
parent666e43aca607c90d95379caa13b42a4ed976e8a7 (diff)
mgmt/glusterd: unify the geo-replication status rpc messages.
the intelligence of determining the type of status command is now at glusterd, rather then explicitly setting it while parsing at cli. Signed-off-by: Kaushik BV <kaushikbv@gluster.com> Signed-off-by: Anand Avati <avati@gluster.com> BUG: 2536 (gsync service introspection) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2536
Diffstat (limited to 'cli/src')
-rw-r--r--cli/src/cli-cmd-parser.c16
1 files changed, 1 insertions, 15 deletions
diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c
index 1449d62fa..70a632751 100644
--- a/cli/src/cli-cmd-parser.c
+++ b/cli/src/cli-cmd-parser.c
@@ -1127,7 +1127,6 @@ cli_cmd_gsync_set_parse (const char **words, int wordcount, dict_t **options)
char *append_str = NULL;
size_t append_len = 0;
int i = 0;
- int32_t status_type = 0;
GF_ASSERT (words);
GF_ASSERT (options);
@@ -1145,18 +1144,7 @@ cli_cmd_gsync_set_parse (const char **words, int wordcount, dict_t **options)
if ((strcmp (words[2], "status")) == 0) {
type = GF_GSYNC_OPTION_TYPE_STATUS;
- if (wordcount == 3)
- status_type = GF_GSYNC_OPTION_TYPE_STATUS_ALL;
- else if (wordcount == 4)
- status_type = GF_GSYNC_OPTION_TYPE_STATUS_MASTER;
- else if (wordcount == 5)
- status_type = GF_GSYNC_OPTION_TYPE_STATUS_MST_SLV;
- else
- goto out;
-
-
- ret = dict_set_int32 (dict, "status-type", status_type);
- if (ret < 0)
+ if (wordcount > 5)
goto out;
if (wordcount < 4)
@@ -1171,8 +1159,6 @@ cli_cmd_gsync_set_parse (const char **words, int wordcount, dict_t **options)
if (ret < 0)
goto out;
-
-
goto set_type;
}