summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorshishir gowda <shishirng@gluster.com>2011-03-18 05:39:16 +0000
committerVijay Bellur <vijay@dev.gluster.com>2011-03-18 20:05:52 -0700
commit9947b5946033c2751abe454efe4c9fd1a7ae7d0b (patch)
tree3fbd626022561348e71cbf20a067b541cfdabc4f
parent1641d8bb4cbe64da024124d943c04da3bf379100 (diff)
Change NFS_PATH_MAX value to 4096
This is tmp fix for crash seen on solaris gnfs server is received path is longer than PATH_MAX. On solaris default PATH_MAX is 1024, and linux default PATH_MAX is 4096. Signed-off-by: shishir gowda <shishirng@gluster.com> Signed-off-by: Vijay Bellur <vijay@dev.gluster.com> BUG: 2476 () URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2476
-rw-r--r--xlators/nfs/server/src/nfs-common.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/xlators/nfs/server/src/nfs-common.h b/xlators/nfs/server/src/nfs-common.h
index ec46336a89b..deca5d422da 100644
--- a/xlators/nfs/server/src/nfs-common.h
+++ b/xlators/nfs/server/src/nfs-common.h
@@ -32,7 +32,9 @@
#include "iatt.h"
#include "uuid.h"
-#define NFS_PATH_MAX PATH_MAX
+//NFS_PATH_MAX hard-coded to 4096 as a work around for bug 2476.
+//nfs server crashes when path received is longer than PATH_MAX
+#define NFS_PATH_MAX 4096
#define NFS_NAME_MAX NAME_MAX
#define NFS_DEFAULT_CREATE_MODE 0644