Re: dealloc and scarce resources
Re: dealloc and scarce resources
- Subject: Re: dealloc and scarce resources
- From: Ken Thomases <email@hidden>
- Date: Thu, 30 Jun 2011 20:26:11 -0500
On Jun 30, 2011, at 3:33 PM, James Merkel wrote:
> So, my guess is that when Instruments shows an FD of -1 it refers to an FD that isn't mine.
What the File Activity instrument is showing in its event list is a certain subset of system calls which operate on file descriptors. It is showing each call. When one of those events shows a file descriptor of -1, it typically means that call failed, because system calls which return file descriptors typically return -1 (or other negative number) to indicate failure.
By the way, since File Activity is only monitoring a subset of file-descriptor-related system calls, you can't necessarily use it to track leaks of file descriptors. I have opened a bug report with Apple about the need for an instrument which tracks all file descriptor activity, but it hasn't had any response.
Regards,
Ken
_______________________________________________
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