Alan,

http://cr.openjdk.java.net/~ksrini/7031166/webrev.1

Fixed it per your suggestions.

Thanks
Kumar



Kumar Srinivasan wrote:
Hi,

Replaces some old nio code which copies over the test sdk to run tests against.
http://cr.openjdk.java.net/~ksrini/7031166/webrev.0/

Thanks
Kumar
I see the original code creates the parent directories if they don't exist so if you want it work the same way then you could change it to:

Path parent = dst.toPath().getParent();
if (parent != null)
   Files.createDirectories(parent);
Files.copy(....);

I see that CommandLineTests.runPack200 gets the absolute path before calling this function. You shouldn't need to do that now. I also see it tests if the target file exists and deletes it before the copy. You can skip that too if you add the REPLACE_EXISTING option to the copy. One other suggestion is to do a static import of StandardCopyOption to avoid the copy going into a second line.

-Alan.

Reply via email to