RFR: 8263402: MemoryLeak: Node hardreferences it's previous Parent after csslayout and getting removed from the scene [v4]

Ambarish Rapte arapte at openjdk.java.net
Wed Apr 7 11:44:17 UTC 2021


On Fri, 26 Mar 2021 12:02:40 GMT, Florian Kirmaier <fkirmaier at openjdk.org> wrote:

>> Fixing a memory leak. 
>> A node hard references its old parent after CSS layout and getting removed. 
>> This shouldn't be the case, this is very counterintuitive.
>> 
>> The fix uses a WeakReference in CSSStyleHelper for firstStyleableAncestor.
>> This should be fine because the CSS should only depend on it if it's still the real parent. 
>> In that case, it doesn't get collected.
>
> Florian Kirmaier has updated the pull request incrementally with one additional commit since the last revision:
> 
>   8263402
>   Minor cleanup based on codereview

looks good to me.

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

Marked as reviewed by arapte (Reviewer).

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


More information about the openjfx-dev mailing list