From 45cfee031062fe40899a6c4c9049d0267b7c7ee6 Mon Sep 17 00:00:00 2001 From: Amar Tumballi Date: Thu, 10 Jun 2010 01:14:56 +0000 Subject: changed the order of gf_log in xlator.c to prevent hang Signed-off-by: Amar Tumballi Signed-off-by: Anand V. Avati BUG: 329 (Replacing memory allocation functions with mem-type functions) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=329 --- libglusterfs/src/xlator.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'libglusterfs') diff --git a/libglusterfs/src/xlator.c b/libglusterfs/src/xlator.c index e9ace1714ca..94a53211a4c 100644 --- a/libglusterfs/src/xlator.c +++ b/libglusterfs/src/xlator.c @@ -940,9 +940,6 @@ xlator_mem_acct_init (xlator_t *xl, int num_types) return -1; } - gf_log(xl->name, GF_LOG_DEBUG, "Allocated mem_acct_rec for %d types", - num_types); - for (i = 0; i < num_types; i++) { ret = LOCK_INIT(&(xl->mem_acct.rec[i].lock)); if (ret) { @@ -950,6 +947,9 @@ xlator_mem_acct_init (xlator_t *xl, int num_types) } } + gf_log(xl->name, GF_LOG_DEBUG, "Allocated mem_acct_rec for %d types", + num_types); + return 0; } -- cgit