On Thu, 25 Jan 2024 11:11:47 GMT, rjolly <[email protected]> wrote:

> ChangedCharSetException is used to amend the charset during read according to 
> html directives. Currently it causes immediate exit of the method which in 
> turn causes failure to load html documents with charset directives (even if 
> the latter must not change after all). This PR restores the catch operation 
> as it was before the use of try with resources.

Verified the fix with the shared test, its working fine.

test/jdk/javax/swing/JEditorPane/8328953/EditorPaneCharset.java line 2:

> 1: /*
> 2:  * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.

Append Copywrite year.

test/jdk/javax/swing/JEditorPane/8328953/EditorPaneCharset.java line 24:

> 22:  */
> 23: 
> 24: /*

We normally place jtreg tags after imports.

test/jdk/javax/swing/JEditorPane/8328953/EditorPaneCharset.java line 46:

> 44:             "<html lang=\"ru\">\n" +
> 45:             "<head>\n" +
> 46:             "    <meta http-equiv=\"Content-Type\" content=\"text/html; 
> charset=windows-1251\">\n" +

Line exceeds column length which we usually restrict to 80...

-------------

PR Review: https://git.openjdk.org/jdk/pull/17567#pullrequestreview-1960096438
PR Review Comment: https://git.openjdk.org/jdk/pull/17567#discussion_r1539054464
PR Review Comment: https://git.openjdk.org/jdk/pull/17567#discussion_r1539055330
PR Review Comment: https://git.openjdk.org/jdk/pull/17567#discussion_r1539061293

Reply via email to