[PATCH] 7006496: Use modern Windows API to retrieve OS DNS servers

2019-11-24 Thread Anuraag Agrawal
Hello, While investigating DNS resolution failure using Netty ( https://github.com/netty/netty/issues/9796), I came across an old JDK bug where on Windows, the list of OS name servers includes those for disabled interfaces (https://bugs.openjdk.java.net/browse/JDK-7006496). This is problematic sin

Re: [PATCH] 7006496: Use modern Windows API to retrieve OS DNS servers

2019-11-24 Thread Bernd Eckenfels
Hello Anuraag, The patch looks like a good idea (especially the additional cleanup for nanos and arraylist) Just a minor thing I noticed there are two comments talking about „comma and space“ but the code below will only tokenize by space. Imguess the comment needs to be fixed, for the next rev

RFR: 8132359 - JarURLConnection.getJarFile() resource leak when file is not found

2019-11-24 Thread Rob McKenna
Hi folks, If a FileNotFoundException is thrown when attempting to load a class from a jar file, a reference to the open JarFile remains even after the loader is closed. The test in the webrev demonstrates the problem by attempting to delete the JarFile after attempting a class load. The deletion

Re: [PATCH] 7006496: Use modern Windows API to retrieve OS DNS servers

2019-11-24 Thread Anuraag Agrawal
Hi Bernd, Thanks for the look and suggestion. I have updated those comments, as well as added several more to explain the native code aspects better which I hope helps future readers of the code. Hope it looks better now. Inline patch follows diff --git a/src/java.base/windows/classes/sun/net/dn