From bccb4b7a63eaa5e32b34c90dfdd5efa5c99b546a Mon Sep 17 00:00:00 2001 From: Pranith Kumar K Date: Sat, 13 Oct 2012 12:06:14 +0530 Subject: mgmt/glusterd: avoid directly using conf->uuid Change-Id: I398c8741b02aa2f34d428c948e93f422e520a9ab BUG: 862834 Signed-off-by: Pranith Kumar K Reviewed-on: http://review.gluster.org/4084 Tested-by: Gluster Build System Reviewed-by: Krishnan Parthasarathi --- xlators/mgmt/glusterd/src/glusterd-syncop.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'xlators/mgmt/glusterd/src/glusterd-syncop.c') diff --git a/xlators/mgmt/glusterd/src/glusterd-syncop.c b/xlators/mgmt/glusterd/src/glusterd-syncop.c index 7c4ae8903cc..6c7bccf9539 100644 --- a/xlators/mgmt/glusterd/src/glusterd-syncop.c +++ b/xlators/mgmt/glusterd/src/glusterd-syncop.c @@ -497,7 +497,7 @@ gd_sync_task_begin (dict_t *op_ctx, char **op_errstr) goto out; /* Lock everything */ - ret = glusterd_lock (conf->uuid); + ret = glusterd_lock (MY_UUID); if (ret) goto out; /* successful lock in local node */ @@ -505,7 +505,7 @@ gd_sync_task_begin (dict_t *op_ctx, char **op_errstr) list_for_each_entry (peerinfo, &conf->peers, uuid_list) { ret = gd_syncop_mgmt_lock (peerinfo->rpc, - conf->uuid, tmp_uuid); + MY_UUID, tmp_uuid); if (ret) goto out; /* TODO: Only on lock successful nodes it should unlock */ @@ -522,7 +522,7 @@ gd_sync_task_begin (dict_t *op_ctx, char **op_errstr) list_for_each_entry (peerinfo, &conf->peers, uuid_list) { ret = gd_syncop_mgmt_stage_op (peerinfo->rpc, - conf->uuid, tmp_uuid, + MY_UUID, tmp_uuid, op, req_dict, &rsp_dict, op_errstr); if (ret) { @@ -550,7 +550,7 @@ gd_sync_task_begin (dict_t *op_ctx, char **op_errstr) list_for_each_entry (peerinfo, &conf->peers, uuid_list) { ret = gd_syncop_mgmt_commit_op (peerinfo->rpc, - conf->uuid, tmp_uuid, + MY_UUID, tmp_uuid, op, req_dict, &rsp_dict, op_errstr); if (ret) { @@ -577,12 +577,12 @@ out: here, and unlock would fail on nodes where lock never was sent */ gd_syncop_mgmt_unlock (peerinfo->rpc, - conf->uuid, tmp_uuid); + MY_UUID, tmp_uuid); } /* Local node should be the one to be locked first, unlocked last to prevent races */ - glusterd_unlock (conf->uuid); + glusterd_unlock (MY_UUID); } if (req_dict) -- cgit