summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaghavendra Bhat <raghavendrabhat@gluster.com>2010-09-15 03:28:48 +0000
committerVijay Bellur <vijay@dev.gluster.com>2010-09-15 02:18:11 -0700
commit3d1a0c2e3787f1c1b6cb1eb45690f36e175e983b (patch)
treec4b504b3947d1990d128e8506d3551a22e1ea553
parent2745bc6a917b356d55b1cbdff1644a2465fa133d (diff)
error out if a peer is not connected or not in befriended state
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Signed-off-by: Vijay Bellur <vijay@dev.gluster.com> BUG: 1603 () URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1603
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-handler.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-handler.c b/xlators/mgmt/glusterd/src/glusterd-handler.c
index 040dff1be8e..a069e0ec582 100644
--- a/xlators/mgmt/glusterd/src/glusterd-handler.c
+++ b/xlators/mgmt/glusterd/src/glusterd-handler.c
@@ -1180,7 +1180,7 @@ glusterd_handle_create_volume (rpcsvc_request_t *req)
err_ret = 1;
goto out;
}
- if ((!peerinfo->connected) &&
+ if ((!peerinfo->connected) ||
(peerinfo->state.state != GD_FRIEND_STATE_BEFRIENDED)) {
snprintf(err_str, 1048, "Host %s not connected",
brickinfo->hostname);