Re: Get PID from Socket Descriptor?
Re: Get PID from Socket Descriptor?
- Subject: Re: Get PID from Socket Descriptor?
- From: Justin Walker <email@hidden>
- Date: Mon, 9 May 2005 14:10:28 -0700
On May 9, 2005, at 13:12, Charlie Boisseau wrote:
Thanks for your answer. I think I'll have to go back to using the
fstat tool, which means including it in the application bundle for
compatibility with 10.4. My only other option is to take out the
feature completely. I'd be a bit aggrieved if this has to happen
because for my Windows port, the netstat command has the functionality
built-in (the -o switch).
Does anyone know how the fstat tool does it? It seems to work quickly
enough.
If you are concerned about the performance of 'lsof', make sure you
understand what is happening, and why it is taking so long. For
example, it might be just hanging around waiting for DNS responses that
will never come. Try 'lsof -n'.
Also, 'fstat' works in much the same way that 'lsof' works (mucking
about in kernel memory). You should check the source.
Regards,
Justin
--
Justin C. Walker, Curmudgeon-At-Large
Institute for General Semantics
--------
When LuteFisk is outlawed,
Only outlaws will have LuteFisk
--------
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden