Menu

#105 Static reference nextDisplayable in Alert class hinders GC

open
nobody
None
5
2009-08-21
2009-08-21
Oben Sonne
No

First of all, thank you for MicroEmulator .. living alone with WTK would be a PITA.

Now to the issue, the title says it already. The static reference is not really a leak, as this reference gets refreshed when a new Alert is displayed so that finally the previous object referenced by Alert.nextDisplayable may get garbage collected. However this reference makes profiling for real memory leaks complicated. Things would be easier if this reference would be an instance field.

Thanks and cheers,
Oben

BTW.. I'm using MicroEmu 2.0.3

Discussion

  • Oben Sonne

    Oben Sonne - 2009-08-21

    An alternative to making it an instance field would be to simply set it null once it has been used.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.