Ah, now that is interesting... I was actually closing the JFrames manually
by clicking the close button on the upper left corner of each window that
appeared (and since I set the default close operation to DISPOSE_ON_CLOSE,
this resulted in dispose() being called on each frame).
Indeed, using
Here is my test code that demonstrates the leak:
http://bonuslord.github.io/misc/FrameLeakDemo.java
In JDK 8 the output indicates 3 frames remaining even after closing all of
the JFrames.
In JDK 9 the output usually reports 1 frame remaining after closing all of
the frames, although sometimes all
On 19.09.16 23:02, Andy Lee wrote:
In JDK 9 the problem seems to be partially fixed; only the most recently
closed JFrame leaks (ie, a temporary leak). I was unable to get Visual
VM to connect to the Java 9 process so I'm not exactly sure what was
preventing the last JFrame from being GC'd.
In JDK 9 the problem seems to be partially fixed; only the most recently
closed JFrame leaks (ie, a temporary leak). I was unable to get Visual VM
to connect to the Java 9 process so I'm not exactly sure what was
preventing the last JFrame from being GC'd.
The Java 9 behavior would be sufficient
On 19.09.16 19:13, Andy Lee wrote:
Yes, I just tried my test case on JDK 8u112 and I can still reproduce
the JFrame leak.
And what about the latest jdk9?
https://jdk9.java.net/download
On Mon, Sep 19, 2016 at 11:26 AM, Sergey Bylokhov
Yes, I just tried my test case on JDK 8u112 and I can still reproduce the
JFrame leak.
On Mon, Sep 19, 2016 at 11:26 AM, Sergey Bylokhov <
sergey.bylok...@oracle.com> wrote:
> Hi, Andy.
> I suggest to check the latest jdk9 and jdk8. Do you able to reproduce this
> bug on jdk8u112?
>
>
> On
Hi, Andy.
I suggest to check the latest jdk9 and jdk8. Do you able to reproduce
this bug on jdk8u112?
On 19.09.16 17:19, Andy Lee wrote:
Not sure if this is the best place to ask, but I'm looking for good way
to prevent the JFrame/JDialog memory leaks caused
by
Not sure if this is the best place to ask, but I'm looking for good way to
prevent the JFrame/JDialog memory leaks caused by
https://bugs.openjdk.java.net/browse/JDK-8029147
The best solution I've found so far is to use reflection to dig in and null
out the 'target' fields on the LWComponentPeer