summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src
diff options
context:
space:
mode:
authorManikandan Selvaganesh <mselvaga@redhat.com>2015-11-26 12:32:10 +0530
committerAtin Mukherjee <amukherj@redhat.com>2015-11-26 19:41:21 -0800
commit0db6d57a184ed79eb3142c42957b1a2415744011 (patch)
tree43ecd01d998088591608372bf827ed94608d8877 /xlators/mgmt/glusterd/src
parent3ef88ec70aefd278155aa485e83a2d7bba8b6663 (diff)
glusterd: glusterfsd to support volfile-server-transport type "unix"
If glusterfsd uses transport type "unix", 'addrstr' can be empty. So, it may fail to fetch the trusted volfile in this case. This patch allows to fetch volfile even if addrstr is empty. Change-Id: I831c5cd0b07b90ae843ec63f0fad9241d9407f6b BUG: 1279484 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Signed-off-by: Mohamed Ashiq <mliyazud@redhat.com> Reviewed-on: http://review.gluster.org/12757 Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Niels de Vos <ndevos@redhat.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-handshake.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-handshake.c b/xlators/mgmt/glusterd/src/glusterd-handshake.c
index e3f949a..755b7aa 100644
--- a/xlators/mgmt/glusterd/src/glusterd-handshake.c
+++ b/xlators/mgmt/glusterd/src/glusterd-handshake.c
@@ -786,8 +786,9 @@ __server_getspec (rpcsvc_request_t *req)
* server, self-heal daemon etc., so that they are not inadvertently
* blocked by a auth.{allow,reject} setting. The trusted volfile is not
* meant for external users.
+ * For unix domain socket, address will be empty.
*/
- if (strlen (addrstr) && gf_is_local_addr (addrstr)) {
+ if (strlen (addrstr) == 0 || gf_is_local_addr (addrstr)) {
ret = build_volfile_path (volume, filename,
sizeof (filename),