From f631ceb79e822bb5c3bbbaa2ad3a28a3f32e4251 Mon Sep 17 00:00:00 2001 From: Sanju Rakonde Date: Sun, 13 May 2018 21:03:12 +0530 Subject: cli: Fix for gluster volume info --xml Problem: gluster volume info --xml is showing same uuid to all the bricks of a tier volume. Solution: While iterating over hot/cold bricks of a tier volume, use correct iterator. Fixes: bz#1577627 Change-Id: Icf6a9c2a10b9da453abc262a57b7884d6638e3ed Signed-off-by: Sanju Rakonde --- cli/src/cli-xml-output.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cli/src/cli-xml-output.c') diff --git a/cli/src/cli-xml-output.c b/cli/src/cli-xml-output.c index 29ee81b6012..a709ed5a6c7 100644 --- a/cli/src/cli-xml-output.c +++ b/cli/src/cli-xml-output.c @@ -2942,7 +2942,7 @@ cli_xml_output_vol_info (cli_local_t *local, dict_t *dict) memset (key, 0, sizeof (key)); snprintf (key, sizeof (key), - "volume%d.brick%d.uuid", i, j); + "volume%d.brick%d.uuid", i, index); ret = dict_get_str (dict, key, &uuid); if (ret) goto out; @@ -3053,7 +3053,7 @@ cli_xml_output_vol_info (cli_local_t *local, dict_t *dict) memset (key, 0, sizeof (key)); snprintf (key, sizeof (key), - "volume%d.brick%d.uuid", i, j); + "volume%d.brick%d.uuid", i, index); ret = dict_get_str (dict, key, &uuid); if (ret) goto out; -- cgit