diff options
author | Kaushal M <kaushal@redhat.com> | 2015-03-24 12:56:09 +0530 |
---|---|---|
committer | Krishnan Parthasarathi <kparthas@redhat.com> | 2015-03-25 04:36:57 -0700 |
commit | 91708968d01b253ee1ebcec1fdc3d602435144ef (patch) | |
tree | 14bc64e84690aa9f2be4b5eb1f98f8ce176f4465 /xlators/mgmt/glusterd/src/glusterd-handler.c | |
parent | 891c7d0fad16e7f0f51af217a8aad0a653a353d7 (diff) |
glusterd: Prevent possible dealock in glusterd_friend_remove
This change was developed on the git branch at [1]. This commit is a
combination of the following commits on the development branch.
b02290e Prevent possible dealock in glusterd_friend_remove
[1]: https://github.com/kshlm/glusterfs/tree/urcu
Change-Id: I1efeaf18f2054f4252ee95244908613542d209d9
BUG: 1205186
Signed-off-by: Kaushal M <kaushal@redhat.com>
Reviewed-on: http://review.gluster.org/9979
Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
Reviewed-by: Gaurav Kumar Garg <ggarg@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Tested-by: Krishnan Parthasarathi <kparthas@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-handler.c')
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-handler.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-handler.c b/xlators/mgmt/glusterd/src/glusterd-handler.c index a41b36b9715..399b0629708 100644 --- a/xlators/mgmt/glusterd/src/glusterd-handler.c +++ b/xlators/mgmt/glusterd/src/glusterd-handler.c @@ -3016,8 +3016,10 @@ glusterd_friend_remove (uuid_t uuid, char *hostname) rcu_read_lock (); peerinfo = glusterd_peerinfo_find (uuid, hostname); - if (peerinfo == NULL) + if (peerinfo == NULL) { + rcu_read_unlock (); goto out; + } ret = glusterd_friend_remove_cleanup_vols (peerinfo->uuid); if (ret) |