summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaghavendra Bhat <raghavendra@redhat.com>2013-10-30 14:30:09 +0530
committershishir gowda <sgowda@redhat.com>2013-11-15 14:45:13 +0530
commitea9051f32f48de658f525bb515f44e2c1e76da33 (patch)
tree2f9fa7248c2ecd501efcaf31bd0f59c013453b55
parentb825cdd286f6fdc015b085079a1e554a6bfd407d (diff)
mgmt/glusterd: set the appropriate status of the snap after create
Change-Id: I58a743c92bbd021c3a42c5184ba8acf4db48878a Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com>
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-snapshot.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-snapshot.c b/xlators/mgmt/glusterd/src/glusterd-snapshot.c
index ad0f5ff..0d12373 100644
--- a/xlators/mgmt/glusterd/src/glusterd-snapshot.c
+++ b/xlators/mgmt/glusterd/src/glusterd-snapshot.c
@@ -2250,6 +2250,8 @@ glusterd_snap_create (glusterd_volinfo_t *volinfo,
goto out;
}
+ snap->snap_status = GD_SNAP_STATUS_IN_USE;
+
out:
if (ret) {
if (snap) {
@@ -2736,6 +2738,7 @@ glusterd_do_snap (glusterd_volinfo_t *volinfo, char *name, dict_t *dict,
}
snap_volume->status = GLUSTERD_STATUS_STARTED;
+
out:
if (ret)
glusterd_volinfo_delete (snap_volume);