RFR: 8319779: SystemMenu: memory leak due to listener never being removed [v7]

Johan Vos jvos at openjdk.org
Thu Jan 11 08:04:59 UTC 2024


> A listener was added but never removed.
> This patch removes the listener when the menu it links to is cleared. Fix for https://bugs.openjdk.org/browse/JDK-8319779

Johan Vos has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains eight additional commits since the last revision:

 - Merge remote-tracking branch 'upstream/master' into 8319779-systemmenu
 - Cleanup test
 - Add shim class so that we can access the references to com.sun.glass.ui.Menu instances.
   Add a test to make sure those references are gone.
 - Revert WeakInvalidationListeners and use new listener resource management approach.
 - Fix more memoryleaks due to listeners never being unregistered.
 - These changes are related to JBS-8318841 so we want to have that code in
   as well.
   
   Merge branch 'master' into 8319779-systemmenu
 - process reviewers comments
 - A listener was added but never removed.
   This patch removes the listener when the menu it links to is cleared.
   Fix for https://bugs.openjdk.org/browse/JDK-8319779

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

Changes:
  - all: https://git.openjdk.org/jfx/pull/1283/files
  - new: https://git.openjdk.org/jfx/pull/1283/files/d5a78749..703fd3c2

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jfx&pr=1283&range=06
 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=1283&range=05-06

  Stats: 290 lines in 39 files changed: 222 ins; 6 del; 62 mod
  Patch: https://git.openjdk.org/jfx/pull/1283.diff
  Fetch: git fetch https://git.openjdk.org/jfx.git pull/1283/head:pull/1283

PR: https://git.openjdk.org/jfx/pull/1283


More information about the openjfx-dev mailing list