• 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
Re: IONotificationPortRef cleanup
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: IONotificationPortRef cleanup


  • Subject: Re: IONotificationPortRef cleanup
  • From: Jim Magee <email@hidden>
  • Date: Fri, 20 Jan 2006 06:58:48 -0800


On Jan 10, 2006, at 2:44 PM, Steve Checkoway wrote:


On Jan 10, 2006, at 2:35 PM, Chris Sarcone wrote:
To be completely clear about this, these leaked ports are not reclaimed when the application exits?

Mach will clean them up for you at task termination. However, whenever you don't need the resource, you should do the proper thing to release it.



Thank you for the clarification. It seems to me that the example should be changed to simply _exit(2) since the ports will be cleaned up.

The problem is that someone will copy the example into a library routine and replace the _exit() with a return. Then they wonder why they leak - since Apple provided the example and it should have managed its resources.


--Jim

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: IONotificationPortRef cleanup
      • From: Steve Checkoway <email@hidden>
References: 
 >IONotificationPortRef cleanup (From: Steve Checkoway <email@hidden>)
 >Re: IONotificationPortRef cleanup (From: Garth Cummings <email@hidden>)
 >Re: IONotificationPortRef cleanup (From: Steve Checkoway <email@hidden>)
 >Re: IONotificationPortRef cleanup (From: Chris Sarcone <email@hidden>)
 >Re: IONotificationPortRef cleanup (From: Steve Checkoway <email@hidden>)

  • Prev by Date: Re: intercepting system calls?
  • Next by Date: Re: MoreBacktrace for i386?
  • Previous by thread: Re: IONotificationPortRef cleanup
  • Next by thread: Re: IONotificationPortRef cleanup
  • Index(es):
    • Date
    • Thread