Re: Socket timeout issue
Re: Socket timeout issue
- Subject: Re: Socket timeout issue
- From: "Peter Sichel" <email@hidden>
- Date: Fri, 7 Sep 2007 09:17:50 -0400
On 9/6/07, Mitchell Laurren-Ring wrote:
>On Sep 6, 2007, at 6:11 PM, Peter Sichel wrote:
>
>> Instead of relying on the connection to timeout, why not register
>> with the System Configuration Framework to be notified when an IP
>> interface changes so you can close any stale connections promptly.
>
>Thanks for the response, Peter. I tried using the reachability APIs,
>but they don't really do what I want. Which API did you have in mind?
>If I could test my socket, that would be ideal.
I asked the SCF to notify me any time an IP address changes using
some Apple supplied sample code (probably written by Quinn).
I'll send you the sample off list.
Detecting when an IPv4 address changes has been very effective
at catching interface transitions such as moving between
ports in the network service order. If you pay attention to
the data passed in the callback, it will tell you which
IP address transitioned and thus which endpoints
need to be recycled.
Kind Regards,
- Peter
_______________________________________________
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