]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
java: add O_WRONLY open flag
authorNoah Watkins <noahwatkins@gmail.com>
Fri, 19 Oct 2012 19:20:40 +0000 (12:20 -0700)
committerNoah Watkins <noahwatkins@gmail.com>
Fri, 26 Oct 2012 20:30:27 +0000 (13:30 -0700)
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
src/java/java/com/ceph/fs/CephMount.java
src/java/native/libcephfs_jni.cc

index 0211f673073c57066cc1f0352cbe5dc8a4a1cde8..f9a6e430a60c3735ebab6e2238916b1c97113e6d 100644 (file)
@@ -44,6 +44,7 @@ public class CephMount {
   public static final int O_CREAT  = 8;
   public static final int O_TRUNC  = 16;
   public static final int O_EXCL   = 32;
+  public static final int O_WRONLY = 64;
 
   /*
    * Whence flags for seek().
index dd23c36d6e180be199c36ed368c007839abe7988..347437c9aa22b176741ae4452f838d996bae95a9 100644 (file)
@@ -53,6 +53,7 @@
 #define JAVA_O_CREAT  8
 #define JAVA_O_TRUNC  16
 #define JAVA_O_EXCL   32
+#define JAVA_O_WRONLY 64
 
 /*
  * Whence flags for seek(). sync with CephMount.java if changed.
@@ -94,6 +95,7 @@ static inline int fixup_open_flags(jint jflags)
        FIXUP_OPEN_FLAG(O_CREAT)
        FIXUP_OPEN_FLAG(O_TRUNC)
        FIXUP_OPEN_FLAG(O_EXCL)
+       FIXUP_OPEN_FLAG(O_WRONLY)
 
 #undef FIXUP_OPEN_FLAG