summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd
diff options
context:
space:
mode:
authorRaghavendra Bhat <raghavendra@redhat.com>2012-06-13 14:24:52 +0530
committerVijay Bellur <vijay@gluster.com>2012-06-13 08:29:51 -0700
commit1877c8ea84adfc6c8943bba806e410de5eba84a7 (patch)
treef8f09bd5a36c7bf6fcc98888e9c166f02214d91c /xlators/mgmt/glusterd
parent2fde351b8228720bc13f8bea3453b6af1d68c5ad (diff)
mgmt/glusterd: fix the infinite loop in lazy uuid generation
* This is how the lazy uuid generation leads to infinite loop of function calls. MY_UUID -> glusterd_uuid_init -> glusterd_retrieve_uuid -> MY_UUID * Also while starting glusterd if valgrind option is not given in the volfile, then reset the ret variable to 0. Change-Id: Ief719f436d8a264a591ee6aefc6da3c0f6c75e8f BUG: 811493 Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com> Reviewed-on: http://review.gluster.com/3564 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Pranith Kumar Karampuri <pranithk@gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
Diffstat (limited to 'xlators/mgmt/glusterd')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-store.c2
-rw-r--r--xlators/mgmt/glusterd/src/glusterd.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-store.c b/xlators/mgmt/glusterd/src/glusterd-store.c
index 68d621571e0..db26bbf2c10 100644
--- a/xlators/mgmt/glusterd/src/glusterd-store.c
+++ b/xlators/mgmt/glusterd/src/glusterd-store.c
@@ -1444,7 +1444,7 @@ glusterd_retrieve_uuid ()
goto out;
}
- uuid_parse (uuid_str, MY_UUID);
+ uuid_parse (uuid_str, priv->uuid);
out:
if (uuid_str)
diff --git a/xlators/mgmt/glusterd/src/glusterd.c b/xlators/mgmt/glusterd/src/glusterd.c
index 766c926b802..0dfffbbed39 100644
--- a/xlators/mgmt/glusterd/src/glusterd.c
+++ b/xlators/mgmt/glusterd/src/glusterd.c
@@ -987,6 +987,8 @@ init (xlator_t *this)
}
INIT_LIST_HEAD (&conf->mount_specs);
+
+ ret = 0;
dict_foreach (this->options, _install_mount_spec, &ret);
if (ret)
goto out;