Re: RFR: 8263905: Remove finalize methods for SocketInput/OutputStream

2021-03-22 Thread Alan Bateman
On Mon, 22 Mar 2021 06:02:37 GMT, Kim Barrett wrote: > Please review this change to java.net.SocketInputStream and > java.net.SocketOutputStream, removing their "finalize" methods. These > methods are empty. Their purpose is to override and suppress the finalize > methods of their superclasses

RFR: 8263899: HttpClient throws NPE in AuthenticationFilter when parsing www-authenticate head

2021-03-22 Thread Michael McMahon
Could I get the following simple fix reviewed please? Thanks, Michael. - Commit messages: - Initial fix Changes: https://git.openjdk.java.net/jdk/pull/3113/files Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=3113&range=00 Issue: https://bugs.openjdk.java.net/browse/JDK-8

Re: RFR: 8263899: HttpClient throws NPE in AuthenticationFilter when parsing www-authenticate head

2021-03-22 Thread Chris Hegarty
On Mon, 22 Mar 2021 09:26:08 GMT, Michael McMahon wrote: > Could I get the following simple fix reviewed please? > > Thanks, > Michael. test/jdk/java/net/httpclient/EmptyAuthenticate.java line 44: > 42: > 43: public static void main(String[] args) throws IOException, > URISyntaxException

Re: RFR: 8263905: Remove finalize methods for SocketInput/OutputStream

2021-03-22 Thread Vyom Tewari
On Mon, 22 Mar 2021 06:02:37 GMT, Kim Barrett wrote: > Please review this change to java.net.SocketInputStream and > java.net.SocketOutputStream, removing their "finalize" methods. These > methods are empty. Their purpose is to override and suppress the finalize > methods of their superclasses

Re: RFR: 8263899: HttpClient throws NPE in AuthenticationFilter when parsing www-authenticate head [v2]

2021-03-22 Thread Michael McMahon
> Could I get the following simple fix reviewed please? > > Thanks, > Michael. Michael McMahon has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four add

Re: RFR: 8263899: HttpClient throws NPE in AuthenticationFilter when parsing www-authenticate head [v2]

2021-03-22 Thread Michael McMahon
On Mon, 22 Mar 2021 09:40:43 GMT, Chris Hegarty wrote: >> Michael McMahon has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains four additional >> com

Re: RFR: 8263899: HttpClient throws NPE in AuthenticationFilter when parsing www-authenticate head [v3]

2021-03-22 Thread Michael McMahon
> Could I get the following simple fix reviewed please? > > Thanks, > Michael. Michael McMahon has updated the pull request incrementally with one additional commit since the last revision: fix whitespace error - Changes: - all: https://git.openjdk.java.net/jdk/pull/3113/files

Re: RFR: 8263905: Remove finalize methods for SocketInput/OutputStream

2021-03-22 Thread Daniel Fuchs
On Mon, 22 Mar 2021 06:02:37 GMT, Kim Barrett wrote: > Please review this change to java.net.SocketInputStream and > java.net.SocketOutputStream, removing their "finalize" methods. These > methods are empty. Their purpose is to override and suppress the finalize > methods of their superclasses

Re: RFR: 8187450: JNI local refs exceeds capacity warning in NetworkInterface::getAll [v4]

2021-03-22 Thread Andrew Haley
On Tue, 16 Mar 2021 14:12:46 GMT, Jonathan Dowland wrote: >> This is an adaptation of a patch originally written by Shafi Ahmad in >> a comment on the JBS page but never submitted or merged. >> >> With -Xcheck:jni, the method java.net.NetworkInterface.getAll very >> quickly breaches the default

Re: RFR: 8187450: JNI local refs exceeds capacity warning in NetworkInterface::getAll [v4]

2021-03-22 Thread Andrew Haley
On Tue, 16 Mar 2021 15:41:21 GMT, Andrew Haley wrote: > Please hold off on this; there's an issue to clear up. Done. - PR: https://git.openjdk.java.net/jdk/pull/2963

Re: RFR: JDK-8257235: [PATCH] InetAddress.isReachable: Try to use an IPPROTO_ICMP socket type before attempting RAW_SOCK [v2]

2021-03-22 Thread Jamie Le Tual
On Fri, 19 Mar 2021 16:47:10 GMT, Chris Hegarty wrote: >>> I think that the changes are mostly good. I would like to try them out on >>> my local system and our internal buildAndTest system. >> >> Chris, were you able to test the patch? >> >> Also if anyone has an idea as to the best way to u

Integrated: 8187450: JNI local refs exceeds capacity warning in NetworkInterface::getAll

2021-03-22 Thread Jonathan Dowland
On Fri, 12 Mar 2021 09:52:13 GMT, Jonathan Dowland wrote: > This is an adaptation of a patch originally written by Shafi Ahmad in > a comment on the JBS page but never submitted or merged. > > With -Xcheck:jni, the method java.net.NetworkInterface.getAll very > quickly breaches the default JNI l

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Michael McMahon
On Tue, 16 Mar 2021 14:19:09 GMT, Julia Boes wrote: > The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable > by wrapping it in an unmodifiable view. Changes requested by michaelm (Reviewer). src/jdk.httpserver/share/classes/sun/net/httpserver/UnmodifiableHeaders.java l

RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Julia Boes
The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable by wrapping it in an unmodifiable view. - Commit messages: - fix imports - Merge branch 'master' into 8263506 - fix UnmodifiableHeaders impl - add initial test Changes: https://git.openjdk.java.net/jdk/

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Julia Boes
On Tue, 16 Mar 2021 14:30:39 GMT, Michael McMahon wrote: >> The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable >> by wrapping it in an unmodifiable view. > > src/jdk.httpserver/share/classes/sun/net/httpserver/UnmodifiableHeaders.java > line 60: > >> 58: m

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Michael McMahon
On Mon, 22 Mar 2021 16:23:27 GMT, Daniel Fuchs wrote: >> The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable >> by wrapping it in an unmodifiable view. > > src/jdk.httpserver/share/classes/sun/net/httpserver/UnmodifiableHeaders.java > line 34: > >> 32: public class Unm

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Michael McMahon
On Mon, 22 Mar 2021 11:56:58 GMT, Julia Boes wrote: >> src/jdk.httpserver/share/classes/sun/net/httpserver/UnmodifiableHeaders.java >> line 60: >> >>> 58: map.forEach((k, v) -> headers.add(k, v.get(0))); >>> 59: return headers.getFirst(key); >>> 60: } >> >> Shou

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Daniel Fuchs
On Tue, 16 Mar 2021 14:19:09 GMT, Julia Boes wrote: > The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable > by wrapping it in an unmodifiable view. src/jdk.httpserver/share/classes/sun/net/httpserver/UnmodifiableHeaders.java line 34: > 32: public class UnmodifiableHea

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Daniel Fuchs
On Mon, 22 Mar 2021 16:30:10 GMT, Michael McMahon wrote: >> src/jdk.httpserver/share/classes/sun/net/httpserver/UnmodifiableHeaders.java >> line 34: >> >>> 32: public class UnmodifiableHeaders extends Headers { >>> 33: >>> 34: private Map> map; >> >> How about: >> >> private final He

Re: RFR: 8263905: Remove finalize methods for SocketInput/OutputStream

2021-03-22 Thread Mandy Chung
On Mon, 22 Mar 2021 06:02:37 GMT, Kim Barrett wrote: > Please review this change to java.net.SocketInputStream and > java.net.SocketOutputStream, removing their "finalize" methods. These > methods are empty. Their purpose is to override and suppress the finalize > methods of their superclasses

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Daniel Fuchs
On Mon, 22 Mar 2021 16:25:24 GMT, Michael McMahon wrote: >> Headers normalizes the key before any get/getFirst, for example Headers line >> 131: >> >> `public List get(Object key) { >> return map.get(normalize((String)key)); >> }` >> >> I assume we want to maintain this beh

Re: RFR: 8263442: Potential bug in jdk.internal.net.http.common.Utils.CONTEXT_RESTRICTED [v3]

2021-03-22 Thread Michael McMahon
> Hi, > > The fix for the reported bug in Utils.CONTEXT_RESTRICTED caused a couple of > regression failures, which turned out to be another bug exposed by this fix > where HTTP/1.1 CONNECT requests with authentication were filtering out proxy > authentication headers wrongly. This was because t

Re: RFR: 8263442: Potential bug in jdk.internal.net.http.common.Utils.CONTEXT_RESTRICTED [v3]

2021-03-22 Thread Michael McMahon
On Mon, 15 Mar 2021 14:57:33 GMT, Michael McMahon wrote: >> test/jdk/java/net/httpclient/AuthFilter.java line 57: >> >>> 55: Headers reqh = e.getRequestHeaders(); >>> 56: if (reqh.containsKey("authorization")) { >>> 57: e.sendResponseHeaders(500, -1); >>