Backporting this fix to jdk8u-dev sources.The jdk9 changeset didn't apply cleanly but the fix in essence is the removal of a try-with-resources block. Tests are green.
bug report : https://bugs.openjdk.java.net/browse/JDK-8136534 webrev : http://cr.openjdk.java.net/~coffeys/webrev.8136534.8u/webrev/ -- Regards, Sean.