Terminating suspended NSTask
If 开发者_如何学运维I terminate (or interrupt) a suspended NSTask, then it still shows up in activity monitor. It isn't running because the CPU is 0% but it's still taking up memory. Is there a work around?
If you have instantiated the NSTask
by using Alloc
/init
, there should be no problem.
The NSTask will eventually get caught by the garbage collector, and the memory will be cleared accordingly.
When the application closes entirely the allocated space and memory will be cleared aswell, like it should.
精彩评论