summaryrefslogtreecommitdiffstats
path: root/libglusterfs
diff options
context:
space:
mode:
authorAmar Tumballi <amarts@redhat.com>2012-07-26 17:16:00 +0530
committerVijay Bellur <vijay@gluster.com>2012-08-13 10:25:24 +0530
commit78fa165b6b7ef852153c971247706f2aa65c655a (patch)
treedb672bcddf0c865b476101ef042fffdcb4e4a9d6 /libglusterfs
parenta9e0bac7e7fee641bc1c62379d48f0376cf15cbd (diff)
acl: enable handling of FMODE_EXEC flag
on linux systems, with open(), we can get below flag as per 'linux/fs.h'. /* File is opened for execution with sys_execve / sys_uselib */ '#define FMODE_EXEC ((fmode_t)0x20)' Instead of adding '#include <linux/fs.h>, its better to copy this absolute number into other variable because then we have to deal with declaring fmode_t etc etc.. With the fix, we can handle the file with '0711' permissions in the same way as backend linux filesystems. Change-Id: Ib1097fc0d2502af89c92d561eb4123cba15713f5 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 843960 Reviewed-on: http://review.gluster.com/3746 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'libglusterfs')
-rw-r--r--libglusterfs/src/glusterfs.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/libglusterfs/src/glusterfs.h b/libglusterfs/src/glusterfs.h
index cdfb64dea84..b17934e2e34 100644
--- a/libglusterfs/src/glusterfs.h
+++ b/libglusterfs/src/glusterfs.h
@@ -33,6 +33,7 @@
#include <sys/poll.h>
#include <pthread.h>
+
#include "list.h"
#include "logging.h"
@@ -41,7 +42,12 @@
#ifndef O_LARGEFILE
/* savannah bug #20053, patch for compiling on darwin */
-#define O_LARGEFILE 0
+#define O_LARGEFILE 0100000 /* from bits/fcntl.h */
+#endif
+
+#ifndef O_FMODE_EXEC
+/* redhat bug 843080, added from linux/fs.h */
+#define O_FMODE_EXEC 040 //0x20
#endif
#ifndef O_DIRECT