summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-replace-brick.c
diff options
context:
space:
mode:
authorKaushal M <kaushal@redhat.com>2016-04-16 07:46:40 +0530
committerKaushal M <kaushal@redhat.com>2016-04-16 07:48:23 +0530
commit95cd42ebda087343ecb7267fa1fd5ac129c756e1 (patch)
tree43a1d3ebdd87a3ebfa860aba339d288e72e39d6e /xlators/mgmt/glusterd/src/glusterd-replace-brick.c
parent1c62ca12df86eedf130de679ac99638a9d0ad82d (diff)
Revert "glusterd: Bug fixes for IPv6 support"
This reverts commit b33f3c95ec9c8112e6677e09cea05c4c462040d0. This commit exposes some issues with management encryption that prevents GlusterFS from operating properly. This will be added again once problems with management encryption are fixed.
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-replace-brick.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-replace-brick.c15
1 files changed, 2 insertions, 13 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-replace-brick.c b/xlators/mgmt/glusterd/src/glusterd-replace-brick.c
index 3b8483847e4..b1266aa032e 100644
--- a/xlators/mgmt/glusterd/src/glusterd-replace-brick.c
+++ b/xlators/mgmt/glusterd/src/glusterd-replace-brick.c
@@ -194,7 +194,6 @@ glusterd_op_stage_replace_brick (dict_t *dict, char **op_errstr,
xlator_t *this = NULL;
gf_boolean_t is_force = _gf_false;
gsync_status_param_t param = {0,};
- char *c = NULL;
this = THIS;
GF_ASSERT (this);
@@ -346,18 +345,8 @@ glusterd_op_stage_replace_brick (dict_t *dict, char **op_errstr,
GD_MSG_NO_MEMORY, "Memory allocation failed");
goto out;
}
-
- /*
- * IPv4 address contains '.' and ipv6 addresses contains ':'
- * So finding the last occurance of ':' to
- * mark the start of brick path
- */
- c = strrchr(dup_dstbrick, ':');
- if (c != NULL) {
- c[0] = '\0';
- host = dup_dstbrick;
- path = c++;
- }
+ host = strtok_r (dup_dstbrick, ":", &savetok);
+ path = strtok_r (NULL, ":", &savetok);
if (!host || !path) {
gf_msg (this->name, GF_LOG_ERROR, 0,