ssize_t fsetxattr (int fd, const char *name, const void *value, size_t size, int flags) { error_t err; err = HURD_DPORT_USE (fd, _hurd_xattr_set (port, name, value, size, flags)); return err ? __hurd_dfail (fd, err) : 0; }
ssize_t setxattr (const char *path, const char *name, const void *value, size_t size, int flags) { error_t err; file_t port = __file_name_lookup (path, 0, 0); if (port == MACH_PORT_NULL) return -1; err = _hurd_xattr_set (port, name, value, size, flags); __mach_port_deallocate (__mach_task_self (), port); return __hurd_fail (err); }
error_t _hurd_xattr_remove (io_t port, const char *name) { return _hurd_xattr_set (port, name, NULL, 0, XATTR_REPLACE); }