about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--include/sys/xattr.h3
-rw-r--r--src/linux/xattr.c15
2 files changed, 18 insertions, 0 deletions
diff --git a/include/sys/xattr.h b/include/sys/xattr.h
index 2801cb85..f926493c 100644
--- a/include/sys/xattr.h
+++ b/include/sys/xattr.h
@@ -20,6 +20,9 @@ ssize_t flistxattr(int filedes, char *, size_t);
 int setxattr(const char *, const char *, const void *, size_t, int);
 int lsetxattr(const char *, const char *, const void *, size_t, int);
 int fsetxattr(int, const char *, const void *, size_t, int);
+int removexattr(const char *, const char *);
+int lremovexattr(const char *, const char *);
+int fremovexattr(int, const char *);
 
 #ifdef __cplusplus
 }
diff --git a/src/linux/xattr.c b/src/linux/xattr.c
index a66ab827..fea0d209 100644
--- a/src/linux/xattr.c
+++ b/src/linux/xattr.c
@@ -45,3 +45,18 @@ int fsetxattr(int filedes, const char *name, const void *value, size_t size, int
 {
 	return syscall(SYS_fsetxattr, filedes, name, value, size, flags);
 }
+
+int removexattr(const char *path, const char *name)
+{
+	return syscall(SYS_removexattr, path, name);
+}
+
+int lremovexattr(const char *path, const char *name)
+{
+	return syscall(SYS_lremovexattr, path, name);
+}
+
+int fremovexattr(int fd, const char *name)
+{
+	return syscall(SYS_fremovexattr, fd, name);
+}