diff options
author | Jeff Sharkey <jsharkey@android.com> | 2015-07-02 12:04:00 -0700 |
---|---|---|
committer | Jeff Sharkey <jsharkey@android.com> | 2015-07-02 13:03:14 -0700 |
commit | 82d076b51f6fe7c1cbd1f37414be36eaaa9b0e56 (patch) | |
tree | 117517ea17821d4134f5b7cdd76d1e0d3d82cbeb /luni/src/main/java/android | |
parent | 505fb9201a6624009659b6083949c9e5428def11 (diff) | |
download | libcore-82d076b51f6fe7c1cbd1f37414be36eaaa9b0e56.zip libcore-82d076b51f6fe7c1cbd1f37414be36eaaa9b0e56.tar.gz libcore-82d076b51f6fe7c1cbd1f37414be36eaaa9b0e56.tar.bz2 |
Add getxattr/setxattr/removexattr syscalls.
Bug: 20275572
Change-Id: I958056f757f095ad6278624e293a5583d9cee822
Diffstat (limited to 'luni/src/main/java/android')
-rw-r--r-- | luni/src/main/java/android/system/Os.java | 6 | ||||
-rw-r--r-- | luni/src/main/java/android/system/OsConstants.java | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/luni/src/main/java/android/system/Os.java b/luni/src/main/java/android/system/Os.java index fcecf18..a1e87c8 100644 --- a/luni/src/main/java/android/system/Os.java +++ b/luni/src/main/java/android/system/Os.java @@ -215,6 +215,8 @@ public final class Os { */ public static int getuid() { return Libcore.os.getuid(); } + /** @hide */ public static int getxattr(String path, String name, byte[] outValue) throws ErrnoException { return Libcore.os.getxattr(path, name, outValue); } + /** * See <a href="http://man7.org/linux/man-pages/man3/if_indextoname.3.html">if_indextoname(3)</a>. */ @@ -389,6 +391,8 @@ public final class Os { */ public static void remove(String path) throws ErrnoException { Libcore.os.remove(path); } + /** @hide */ public static void removexattr(String path, String name) throws ErrnoException { Libcore.os.removexattr(path, name); } + /** * See <a href="http://man7.org/linux/man-pages/man2/rename.2.html">rename(2)</a>. */ @@ -468,6 +472,8 @@ public final class Os { */ public static void setuid(int uid) throws ErrnoException { Libcore.os.setuid(uid); } + /** @hide */ public static void setxattr(String path, String name, byte[] value, int flags) throws ErrnoException { Libcore.os.setxattr(path, name, value, flags); }; + /** * See <a href="http://man7.org/linux/man-pages/man2/shutdown.2.html">shutdown(2)</a>. */ diff --git a/luni/src/main/java/android/system/OsConstants.java b/luni/src/main/java/android/system/OsConstants.java index dd6301b..8832f3d 100644 --- a/luni/src/main/java/android/system/OsConstants.java +++ b/luni/src/main/java/android/system/OsConstants.java @@ -496,6 +496,8 @@ public final class OsConstants { public static final int WSTOPPED = placeholder(); public static final int WUNTRACED = placeholder(); public static final int W_OK = placeholder(); + /** @hide */ public static final int XATTR_CREATE = placeholder(); + /** @hide */ public static final int XATTR_REPLACE = placeholder(); public static final int X_OK = placeholder(); public static final int _SC_2_CHAR_TERM = placeholder(); public static final int _SC_2_C_BIND = placeholder(); |