diff options
author | Rajesh Joseph <rjoseph@redhat.com> | 2014-05-05 13:37:34 +0530 |
---|---|---|
committer | Vijay Bellur <vbellur@redhat.com> | 2014-07-12 09:50:25 -0700 |
commit | 656e6b38189d14c440a46d4d69b5ddfc5d8cfffc (patch) | |
tree | 6c8b5c8125258816b18e79cd0e342014892d4cbe /xlators/mgmt/glusterd/src/glusterd-utils.c | |
parent | 99685f18f190a73f2a46478cac0b09f4c59834b1 (diff) |
cli/snapshot: provide --xml support for all snapshot command
Now --xml option can be used with all snapshot command. It
will form the cli output in xml form.
Change-Id: Ifc0ac31d2a9f91e136e87f3b51a629df7dba94e8
BUG: 1096610
Signed-off-by: Rajesh Joseph <rjoseph@redhat.com>
Reviewed-on: http://review.gluster.org/7663
Reviewed-by: Sachin Pandit <spandit@redhat.com>
Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-utils.c')
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-utils.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-utils.c b/xlators/mgmt/glusterd/src/glusterd-utils.c index aff2356eb4f..baa845b0a91 100644 --- a/xlators/mgmt/glusterd/src/glusterd-utils.c +++ b/xlators/mgmt/glusterd/src/glusterd-utils.c @@ -10796,6 +10796,19 @@ glusterd_snap_create_use_rsp_dict (dict_t *dst, dict_t *src) goto out; } + ret = dict_get_str (src, "snapuuid", &buf); + if (ret) { + gf_log (this->name, GF_LOG_ERROR, "failed to get snap UUID"); + goto out; + } + + ret = dict_set_dynstr_with_alloc (dst, "snapuuid", buf); + if (ret) { + gf_log (this->name, GF_LOG_ERROR, + "Failed to set snap uuid in dict"); + goto out; + } + /* set in dst dictionary soft-limit-reach only if soft-limit-reach * is present src dictionary */ ret = dict_get_int8 (src, "soft-limit-reach", &soft_limit_flag); |