equal
deleted
inserted
replaced
96 private boolean isExtendedAttributesEnabled(UnixPath path) { |
96 private boolean isExtendedAttributesEnabled(UnixPath path) { |
97 try { |
97 try { |
98 int fd = path.openForAttributeAccess(false); |
98 int fd = path.openForAttributeAccess(false); |
99 try { |
99 try { |
100 // fgetxattr returns size if called with size==0 |
100 // fgetxattr returns size if called with size==0 |
101 LinuxNativeDispatcher.fgetxattr(fd, "user.java".getBytes(), 0L, 0); |
101 byte[] name = Util.toBytes("user.java"); |
|
102 LinuxNativeDispatcher.fgetxattr(fd, name, 0L, 0); |
102 return true; |
103 return true; |
103 } catch (UnixException e) { |
104 } catch (UnixException e) { |
104 // attribute does not exist |
105 // attribute does not exist |
105 if (e.errno() == UnixConstants.ENODATA) |
106 if (e.errno() == UnixConstants.ENODATA) |
106 return true; |
107 return true; |