[
https://issues.apache.org/jira/browse/PIVOT-861?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13552649#comment-13552649
]
Sandro Martini commented on PIVOT-861:
--------------------------------------
Hi Ćukasz, thanks for the new info.
I can try to take a look at this (so if possible we could fix even this in
2.0.3 final), but please could you attach here a small sample so I can see the
problem ?
This would speedup a lot my tests ...
> If I remove icon form problematic button memory accumulates in another button
> or ImageView instance.
Excuse me but it's not so clear ... could you post some screenshot ?
> Is there any fix or workaround for this problem that I can use before new
> version of pivot will be released?
First I'd say you could try to not use icons in buttons, while not use other
ImageView is not a good workaround ... so really we have to fix this.
Your application run with Java 6 or 7 (where some tricks with Classloaders is
now posible, like close) ?
> Memory leak: Window icon ImageListenerList retains reference to closed
> windows, preventing garbage collection
> -------------------------------------------------------------------------------------------------------------
>
> Key: PIVOT-861
> URL: https://issues.apache.org/jira/browse/PIVOT-861
> Project: Pivot
> Issue Type: Bug
> Components: wtk, wtk-media
> Affects Versions: 2.0.2
> Environment: Windows XP, Java 1.7.0_05
> Reporter: David Keen
> Assignee: Sandro Martini
> Fix For: 2.0.3
>
> Attachments: leaktest.zip, Pivot861.launch
>
>
> When a window or dialog is opened which has an icon, after it is closed it
> cannot be garbage collected because a reference is retained to it through the
> icon. Removing the icon resolves the issue.
> As far as I've investigated, the issue appears to the in the
> ImageListenerList which each Image contains. I've done a heapdump of my
> application and used the IBM HeapAnalyzer which shows this list containing a
> reference to the window/dialog through the ImageViewSkin, but I don't know
> the Pivot internals well enough to see where or how it should be released.
> I'll attach a simple test application to show the issue.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira