RFR: 8241455: ChoiceBox - memory leak on replacing selectionModel

Jeanette Winzenburg fastegal at openjdk.java.net
Mon Mar 23 16:36:49 UTC 2020


ChoiceBox leaves a memory leak when replacing the selectionModel. Culprit is ChoiceBoxSelectionModel which registers
listener with strong references. Fix is to change these to weak references.

Added test that fails before and passes after the test.

for convenience, the bug reference https://bugs.openjdk.java.net/browse/JDK-8241455

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

Commit messages:
 - 8241455: ChoiceBox - memory leak on replacing selectionModel

Changes: https://git.openjdk.java.net/jfx/pull/148/files
 Webrev: https://webrevs.openjdk.java.net/jfx/148/webrev.00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8241455
  Stats: 50 lines in 2 files changed: 42 ins; 0 del; 8 mod
  Patch: https://git.openjdk.java.net/jfx/pull/148.diff
  Fetch: git fetch https://git.openjdk.java.net/jfx pull/148/head:pull/148

PR: https://git.openjdk.java.net/jfx/pull/148


More information about the openjfx-dev mailing list