CFMessagePortCreateLocal() fails occasionally in 10.9?
CFMessagePortCreateLocal() fails occasionally in 10.9?
- Subject: CFMessagePortCreateLocal() fails occasionally in 10.9?
- From: Jerry Krinock <email@hidden>
- Date: Sat, 28 Dec 2013 11:24:35 -0800
Last week I received a second error report from a Mavericks user, via my app’s built-in error reporter, indicating that CFMessagePortCreateLocal() returned NULL. I have no record of this happening prior to Mavericks. Both users report that the operations succeeded when they retried it.
Has anyone else noticed this, or have any knowledge of why it might be occurring?
To try and remedy it, I’ve now added a loop around my call to CFMessagePortCreateLocal() so that it will wait 1 second and retry, up to 5 seconds.
My app normally runs with less than 200 ports open, and my code explicitly creates only a handful. According to Activity Monitor, some apps (Apple’s MainStage 2) have thousands, as does launchd. So I added some test code which created 10,000 ports. It worked with no trouble.
Jerry
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden