Further UserDefinedFileAttributeView improvements and fixes

Sebastian Stenzel sebastian.stenzel at gmail.com
Wed Mar 10 21:20:52 UTC 2021


Resending from my phone, as I think the mailing list failed to process mime format from Apple Mail.

> Am 10.03.2021 um 18:23 schrieb Sebastian Stenzel <sebastian.stenzel at gmail.com>:
> 
> 
>> On 10. Mar 2021, at 17:47, Alan Bateman <Alan.Bateman at oracle.com> wrote:
>> 
>>> On 10/03/2021 16:42, Sebastian Stenzel wrote:
>>> I started working on JDK-8262958 as well, now. Since it will contain multiple changes that build upon each other, I want to ask how to deal with it.
>>> 
>>> My suggestion: I keep this PR a draft for now and have you review each change for itself. Or does it _need_ to be marked RFR to spit out individual webrevs?
>> Small changes are usually easier to review. So if it can be broken up in a sequence of small changes, each with its own JBS and PR, then it would be easier I think.
>> 
>> -Alan
> 
> 
> Is there no way to review increments? After all, JDK-8262958 addresses several related tasks. All we would need is a way to review individual commits instead of the PR as a whole.
> 
> But yes, we certainly can subdivide it further: I'd need you to replace JDK-8262958 by a three more issues:
> 
> 1. Deduplicate code around `flistxattr` calls inside of UnixUserDefinedFileAttributeView.java
> 2. Fix UnsupportedOperationException when passing a ByteBuffer without a backing array to `UnixUserDefinedFileAttributeView.read(String name, ByteBuffer dst)`
> 3. Use try-with-resource for all NativeBuffers within UnixUserDefinedFileAttributeView, fixing leak when opening a file for read/write attr fails (in lines [1] and [2])
> 
> [1]: https://github.com/openjdk/jdk/blob/7e52a6e8b37412b43b0024ca067959100c14f508/src/java.base/unix/classes/sun/nio/fs/UnixUserDefinedFileAttributeView.java#L187
> [2]: https://github.com/openjdk/jdk/blob/7e52a6e8b37412b43b0024ca067959100c14f508/src/java.base/unix/classes/sun/nio/fs/UnixUserDefinedFileAttributeView.java#L258
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.java.net/pipermail/nio-dev/attachments/20210310/a618f53a/attachment.htm>


More information about the nio-dev mailing list