• Post Reply Bookmark Topic Watch Topic
  • New Topic

Console output retained in char[] causes OutOfMemoryError

 
Jon Pincott
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've got an applet that keeps running out of memory. A heap dump analysis shows that the culprit is a char[] owned by the traceMsgQueueThread that contains the entire contents of the java console output. This grows over time as log messages are sent to the console until eventually the applet runs out of memory.

This only seems to occur for a handful of clients, and has been seen on various JREs from pre 1.5 to 1.6.0_10.

Has anyone seen this before, or know what to do about it?
 
Gravity is a harsh mistress. But this tiny ad is pretty easy to deal with:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!