Give default value of O_NOFOLLOW if it is not defined
Alan.Bateman at oracle.com
Thu Jan 12 01:43:07 PST 2012
On 12/01/2012 07:02, Charles Lee wrote:
> Hi Alan,
> Thank you for your review. I have upload a new version on
> <http://cr.openjdk.java.net/%7Elittlee/7129029/webrev.00/> .
> Would you please help to check it again? Apart from your suggestion, I
> also make some changes in UnixCopyFile.java. The situation is the same
> as it is in the UnixChannelFactory.java.
> Thanks in advance :-)
The changes to UnixCopyFile.java will break copying of sym links (in
Files.copy you'll see that it is specified to support NOFOLLOW_LINKS).
The implementation doesn't depend on O_NOFOLLOW support so I don't think
any changes are required.
UnixChannelFactory.java L224 - this needs to throw UnixException rather
than UOE. This will be handled and translated into the appropriate
IOException (actually FileSystemException).
Otherwise the changes look okay to me.
More information about the nio-dev