Skip to main content

Memory leaks....

5 replies [Last post]
Joined: 2006-02-17

I like this project and I love the clean API. Thanks to all the developers who have put their time into this. However....

I tried using the systray integration in Windows in mid August and there was a *huge* memory leak... Accidentally left it running once and a few hours later it had consumed over a hundred megs of RAM. So I ended up using a windows-only solution from

I'm just wondering if it's safe to try again. Have all the memory leaks been fixed? I like the JDIC API much better, and I'd use it if I could. Cross-Platform support is awesome :)


Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2004-09-15

I just wanted to say that we have had a problem with
WebBrowser and using the WebBrowserListener. When
I have a webbrowser object and then add a listener to it (WebBrowserListener), we notice a memory leak. Basically,
I can open and close my gui and for some reason, i leask memory (verified with netbeans). I only remove the listener (the methods implemented did nothing) and the memory leak is gone. It seems like the inner class I added for the listener kept a reference to "this", the complex screen that contains the webbrowser, and disposing the JFrame housing the webbrowser dosn't seem to GC. anyhow, I just removed the listener and all is well.

Joined: 2003-08-14

Was it an animated icon that you were using?

I also have seen the animated icon consume a lot of memory. Howerver, in my case it didn't seem to go past a certain limit (~64MB) so I assumed it wasn't a memory leak and that it was just Java making use of the free resources and not aggresivly collecting it. Were it a memory leak, I believe it would exit with an OutOfMemoryError which I couldn't get it to do. It also consumed 3% of the CPU cycles on a 1.3Ghz Duron (in Windows XP) which was alarming.

It would be nice to see less garbage created and less CPU cycles used by the animated icon but I'm not concerned at all - I just use the static icon (changing it when I need). The static icon uses hardly any CPU or memory and gives you more complete control. You can still animate it by changing it regularly - just use a very low frame rate and you'll be fine.


Joined: 2006-02-17

I can't recall... it might have been when I was experimenting with animated icons. Is that not considered a bug, that using an animated icon could cause a simple taskbar application to use dozens of megabytes of Ram?

Good to know that doesn't happen to you now though (when using static icons, at least)

Thanks for the reply!

Joined: 2003-06-16

Yes we did fix a big memory leak on Windows. So you
should not see it anymore. After fixing it we ran it for
several days without any growth. Please try the latest
version on the download site.



Gary Orser

Hi all,

I'm somewhat new to the jdic project and wanted to run
something by the group which puzzles me.

I've used the mime/type, file type association in our project
and think that it is fantastic.

However I've just tried to use Desktop.browse, and think that there
is a conceptual slip here. The fundamental purpose of the api is
to keep the user and/or programmer from having to muck around.
This setting of environment variables, and placing of embedded executables
in the proper places, seems to be against the whole philosophy of java
web start. This makes for an installation nightmare.

Are there any plans to try and discover/forcefully setup what should be
the correct setup, and automagically set up all environment variables,
before the .browse() is executed in another process?

Cheers, Gary
Gary Orser , orser at cns dot montana dot edu
Montana State University
Center for Computational Biology
1 Lewis Hall, Bozeman MT, 59717

To unsubscribe, e-mail:
For additional commands, e-mail: