summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorshishir gowda <shishirng@gluster.com>2011-03-18 05:37:24 +0000
committerVijay Bellur <vijay@dev.gluster.com>2011-03-18 20:36:48 -0700
commit24d326a5180adaedf8d49a2d087afa0ec470a537 (patch)
tree7efccc6c48f39f329cd043f94c6b50b5c1b1e40b
parentdece0547259a5d73fd6c2616802f83388b5ff4da (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 ec46336a8..deca5d422 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