mbien commented on code in PR #4654:
URL: https://github.com/apache/netbeans/pull/4654#discussion_r977201017


##########
platform/openide.filesystems/src/org/openide/filesystems/FileUtil.java:
##########
@@ -567,6 +569,7 @@ static FileObject copyFileImpl(FileObject source, 
FileObject destFolder, String
             }
 
             copy(bufIn, bufOut);
+            copyPosixPerms(source, dest);
             copyAttributes(source, dest);

Review Comment:
   just a thought:
   Files.copy(...) would copy posix permissions too (there is also a 
COPY_ATTRIBUTES option). Alternative impl would check if its an actual file 
first, if it is, it would use Files.copy() with paths, otherwise use streams.
   
   Maybe its worth thinking about refreshing this code if it isn't too much 
work? Otherwise we end up reimplementing everything what Files.copy already 
does.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to