cluster: STABLE3 - rgmanager: Fix 2+ simultaneous relocation crash

Lon Hohberger lon at fedoraproject.org
Mon Mar 29 13:47:48 UTC 2010


Gitweb:        http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=bed786ea60f0d63d97b06f8c830600e069900528
Commit:        bed786ea60f0d63d97b06f8c830600e069900528
Parent:        9f3163869167555201a408d2e1e1a2890b04d9b3
Author:        Lon Hohberger <lhh at redhat.com>
AuthorDate:    Fri Mar 26 16:57:45 2010 -0400
Committer:     Lon Hohberger <lhh at redhat.com>
CommitterDate: Mon Mar 29 09:46:38 2010 -0400

rgmanager: Fix 2+ simultaneous relocation crash

If you tried to relocate a service twice at the same time,
rgmanager would crash because it would close the
connection twice.

This was reproduced on 3.0.9

Resolves: bz577856

Signed-off-by: Lon Hohberger <lhh at redhat.com>
Signed-off-by: Fabio M. Di Nitto <fdinitto at redhat.com>
---
 rgmanager/src/daemons/rg_thread.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/rgmanager/src/daemons/rg_thread.c b/rgmanager/src/daemons/rg_thread.c
index 5d22968..517f8fe 100644
--- a/rgmanager/src/daemons/rg_thread.c
+++ b/rgmanager/src/daemons/rg_thread.c
@@ -717,7 +717,7 @@ rt_enqueue_request(const char *resgroupname, int request,
 		/* EWOULDBLOCK */
 		pthread_mutex_unlock(resgroup->rt_queue_mutex);
 		pthread_mutex_unlock(&reslist_mutex);
-		return -1;
+		return 0;
 	}
 
 	ret = rq_queue_request(resgroup->rt_queue, resgroup->rt_name,


More information about the cluster-commits mailing list