summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVijay Bellur <vijay@gluster.com>2010-08-06 07:49:36 +0000
committerAnand V. Avati <avati@dev.gluster.com>2010-08-09 04:12:54 -0700
commitb0304d47f67aa8fa677e4898fa46b96df88c8322 (patch)
treedcfd6eeb074bf7e2edb973fda29373325761caf8
parent4f4dcb98a7bd55e84b3bb1d0bdf57cdd9090fcee (diff)
glusterd: Set right return value during delete volume
Signed-off-by: Vijay Bellur <vijay@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 1191 () URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1191
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-op-sm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c
index 8f6861417be..b70705508bb 100644
--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c
+++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c
@@ -477,6 +477,7 @@ glusterd_op_stage_delete_volume (gd1_mgmt_stage_op_req *req)
gf_log ("", GF_LOG_ERROR, "Volume with name %s does not exist",
volname);
ret = -1;
+ goto out;
} else {
ret = 0;
}
@@ -492,6 +493,7 @@ glusterd_op_stage_delete_volume (gd1_mgmt_stage_op_req *req)
gf_log ("", GF_LOG_ERROR, "Volume %s has been started."
"Volume needs to be stopped before deletion.",
volname);
+ ret = -1;
goto out;
}