• 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: Time out a connect() call
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Time out a connect() call


  • Subject: Re: Time out a connect() call
  • From: Nathan Sims <email@hidden>
  • Date: Mon, 21 Nov 2011 12:27:48 -0800

> On Feb 28, 2011, at 3:28 PM, Vincent Lubet wrote:
>>
>> On Feb 28, 2011, at 3:18 PM, Nathan Sims wrote:
>>>
>>> On Feb 28, 2011, at 1:19 PM, Josh Graessley wrote:
>>>
>>>> There is a socket option that will let you adjust the TCP connection timeout. Changing the timeout does not address the issue that 5 seconds can feel like an eternity, and any timeout short enough to not feel like an eternity is unlikely to be long enough to satisfy every situation.
>>>
>>> Do you mean socket option SO_RCVTIMEO or is there one specifically for connect()? The reason I'm wanting to set it down so low is because it's for use on a dedicated intranet, and the destination is either there or it's not, so 5 to 10 seconds is generous in this case.
>>
>> No, Josh was referring to TCP_CONNECTIONTIMEOUT from <netinet/tcp.h>

The above works great on TCP sockets. Now I have a socket(AF_UNIX, SOCK_DGRAM, 0) and want to specify a timeout value on a recvfrom() call to that socket. I can't find a UDP equivalent to TCP_CONNECTIONTIMEOUT. How can I time out the recvfrom() call?

 _______________________________________________
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

  • Follow-Ups:
    • RE: Time out a connect() call
      • From: Satish Kilaru <email@hidden>
  • Prev by Date: Re: new device insertion process
  • Next by Date: RE: Time out a connect() call
  • Previous by thread: Re: new device insertion process
  • Next by thread: RE: Time out a connect() call
  • Index(es):
    • Date
    • Thread