On Sun, 26 Apr 2026 06:12:54 GMT, Jaikiran Pai <[email protected]> wrote:
> Can I please get a review of this test-only change which addresses the issue > noted in https://bugs.openjdk.org/browse/JDK-8308878? > > The commit in this PR updates the test to not hardcode a IPv4 address and > instead use the server's bound address when looking for the server's IP > address in the output. > > With this change the test now passes in IPv4 as well as IPv6 environments. > > --------- > - [x] I confirm that I make this contribution in accordance with the [OpenJDK > Interim AI Policy](https://openjdk.org/legal/ai). test/jdk/com/sun/net/httpserver/simpleserver/OutputFilterTest.java line 134: > 132: var filterOutput = baos.toString(UTF_8); > 133: System.err.println("server output:\n" + filterOutput); > 134: var pattern = Pattern.compile(serverIP + " " + """ For correctness, should this use `Pattern#quote`? Otherwise the `.` in IPv4 addresses would match any character? (also applies to the other changes below) Suggestion: var pattern = Pattern.compile(Pattern.quote(serverIP) + " " + """ ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/30934#discussion_r3148380489
