A small oversight in the implementation of Files.createTempFile and createTempDirectory. If the temporary directory is specified as null then NPE should be thrown. The webrev with the changes is here: http://cr.openjdk.java.net/~alanb/7023034/webrev/ Thanks, Alan.