jdk icon indicating copy to clipboard operation
jdk copied to clipboard

8340554: Improve MessageFormat readObject checks

Open justin-curtis-lu opened this issue 4 months ago • 4 comments

Please review this PR which improves the readObject logic for j.text.MessageFormat.

No offset should be larger than the pattern length. We already ensure the offsets when consumed backwards are equal/descending. The existing first/initial check was off by 1 since it was checking against the pattern length + 1; (see L2040 and L2043).

Please see the JBS issue for further info and other test details.


Progress

  • [x] Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • [x] Change must not contain extraneous whitespace
  • [x] Commit message must refer to an issue

Issue

  • JDK-8340554: Improve MessageFormat readObject checks (Bug - P4)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/21570/head:pull/21570
$ git checkout pull/21570

Update a local copy of the PR:
$ git checkout pull/21570
$ git pull https://git.openjdk.org/jdk.git pull/21570/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 21570

View PR using the GUI difftool:
$ git pr show -t 21570

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/21570.diff

Webrev

Link to Webrev Comment

justin-curtis-lu avatar Oct 17 '24 20:10 justin-curtis-lu