On Wed, 17 Jun 2026 19:37:28 GMT, Anthony Scarpino <[email protected]> wrote:
> I need a review for this bug fix causing intermittent test failures. There > is a reachability fence issue with PEM.java when accessing the `content`. > > Thanks > > --------- > - [x] I confirm that I make this contribution in accordance with the [OpenJDK > Interim AI Policy](https://openjdk.org/legal/ai). src/java.base/share/classes/java/security/PEM.java line 174: > 172: this.type = type; > 173: final var c = content; > 174: CleanerFactory.cleaner().register(this, () -> KeyUtil.clear(c)); Should we put a comment here explaining that `reachabilityFence` calls below are needed to avoid a race condition with a Cleaner zeroing the `context` byte array while one of these methods is still operating on it? ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/31564#discussion_r3436508874
