RFR: 8322881: java/nio/file/Files/CopyMoveVariations.java fails with AccessDeniedException due to permissions of files in /tmp [v3]

Brian Burkhalter bpb at openjdk.org
Wed Feb 21 21:09:55 UTC 2024


On Mon, 19 Feb 2024 09:50:18 GMT, yaqsun <duke at openjdk.org> wrote:

>> testcase: java/nio/file/Files/CopyMoveVariations.java
>> 
>> Method createTempFile() creates "/tmp/file*" that it causes file copy permission issue when running through jtreg.
>> 
>> The method call `Files.move(source, target, options)` by Regular User causes AccessDeniedException due to ` /tmp/file*` is created when running through jtreg.
>> 
>> Create files for method "createTempFile()" passing in the current path(jtreg_test_jdk_java_nio_file_Files_CopyMoveVariations_java/scratch or JTwork/scratch).
>
> yaqsun has updated the pull request incrementally with one additional commit since the last revision:
> 
>   8322881: Method createTempFile() causes file copy permission issue when running through jtreg

I have not been able to reproduce the failure. I am of the opinion however that the problem is due to something local to the test system, e.g., permissions on `/tmp`, a `umask` setting, etc. That said, I think it's good to change the test directory from `/tmp` to `.` so the change in 034324c0df286203b3b718898c9538f565fb6232 is fine. I will approve this PR tomorrow unless there are objections.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/17235#issuecomment-1957935609


More information about the nio-dev mailing list