summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVijay Bellur <vijay@gluster.com>2010-09-25 04:40:33 +0000
committerVijay Bellur <vijay@dev.gluster.com>2010-09-25 04:05:06 -0700
commitcb1c1d78a3aededcc1d1f77f6e91e23fda83a631 (patch)
tree33df9bbcc750eabdbf316430a29116677abb9ab6
parent0b68f788a8ff0579f70e546bcd365ee0c3a49a12 (diff)
mgmt/glusterd: Do not look into brick when logfile is being set for volume
Signed-off-by: Vijay Bellur <vijay@gluster.com> Signed-off-by: Vijay Bellur <vijay@dev.gluster.com> BUG: 971 (dynamic volume management) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=971
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-op-sm.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c
index 236197681..e8aa93b4f 100644
--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c
+++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c
@@ -2999,15 +2999,13 @@ glusterd_op_log_filename (gd1_mgmt_stage_op_req *req)
if (uuid_compare (brickinfo->uuid, priv->uuid))
continue;
- brick_path = strchr (brick, ':');
- brick_path++;
+ if (brick) {
+ brick_path = strchr (brick, ':');
+ brick_path++;
- if (brick_path && strcmp (brickinfo->path, brick_path))
- continue;
-
- GLUSTERD_REMOVE_SLASH_FROM_PATH (brickinfo->path, exp_path);
- if (brick && strcmp (brickinfo->path, brick))
- continue;
+ if (brick_path && strcmp (brickinfo->path, brick_path))
+ continue;
+ }
GLUSTERD_REMOVE_SLASH_FROM_PATH (brickinfo->path, exp_path);