RFR: 8279214: Memory leak in Scene after dragging a cell
Andy Goryachev
angorya at openjdk.org
Wed Sep 14 20:33:10 UTC 2022
On Wed, 14 Sep 2022 18:44:14 GMT, Marius Hanl <mhanl at openjdk.org> wrote:
> This PR fixes a memory leak in dnd code in the `MouseHandler` of a `Scene`.
> The memory leak occurs after calling `startFullDrag()`. The `fullPDRTmpTargetWrapper` is then populated but never cleared.
> Fix is to call `clear()` on the `fullPDRTmpTargetWrapper`, very similar to https://github.com/openjdk/jfx/pull/448 ([JDK-8264330](https://bugs.openjdk.java.net/browse/JDK-8264330)).
Marked as reviewed by angorya (Author).
modules/javafx.graphics/src/main/java/javafx/scene/Scene.java line 3671:
> 3669: pdrEventTarget.clear();
> 3670: pdrEventTargets.clear();
> 3671: fullPDRTmpTargetWrapper.clear();
the change looks ok to me.
is this the only place where the clear() is needed?
-------------
PR: https://git.openjdk.org/jfx/pull/899
More information about the openjfx-dev
mailing list