RFR: 8311030: ResourceBundle.handleKeySet() is racy

Viktor Klang duke at openjdk.org
Thu Jun 29 12:27:55 UTC 2023


On Thu, 29 Jun 2023 10:08:27 GMT, Sergey Tsypanov <stsypanov at openjdk.org> wrote:

>> Looks ok; was this a tool detected race?
>
> @RogerRiggs no tool, just fell into the sources while debugging my application

@stsypanov I don't see that there's any issue with the existing code as the volatile field is only written at most once as guarded by the synchronized-block. Best case this patch avoids an extra volatile read (presuming it isn't optimized away).

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

PR Comment: https://git.openjdk.org/jdk/pull/14692#issuecomment-1613070489


More information about the core-libs-dev mailing list