• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Cocoa Java Memory Leak?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Cocoa Java Memory Leak?


  • Subject: Cocoa Java Memory Leak?
  • From: Brian Hannan <email@hidden>
  • Date: Thu, 26 Jun 2003 17:42:47 -0700

I'm using Cocoa Java and noticing some strange behavior.

Take Java Sketch, one of Apple's Java Cocoa examples. It is doing something my simple NSDocument and NSTextView Cocoa Java app is doing.

If I create a new document and close it, memory for some reason is kept around, ie the resident memory size for the process will not decrease. Open 50 new documents in Java Sketch and immediately close them to see the obscene memory bloat. According to the VM, objects are not kept around, via checks with Runtime.totalMemory() and Runtime.freeMemory(). So I'm guessing in the app's memory the Objective-C side objects are, for some reason, being kept around even though their Java counterparts are being freed by the Java VM.

Is there some special Foundation or AppKit code I need to call, seeing as Java has no explict memory free model, having garbage collection?

Thanks for the help.

--
Brian Hannan
Chief Admiral of Uncle Jam's Navy

"One nation under a groove, gettin' down just for the FUNK of it."
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: sending Apple event from Cocoa application
  • Next by Date: Need to generate multiple print pages on the fly
  • Previous by thread: Re: WWDC 2002 videos
  • Next by thread: Need to generate multiple print pages on the fly
  • Index(es):
    • Date
    • Thread