• 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: FD_CLOSE event occurs on a socket
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FD_CLOSE event occurs on a socket


  • Subject: Re: FD_CLOSE event occurs on a socket
  • From: Jeremy Wyld <email@hidden>
  • Date: Thu, 9 Dec 2004 10:54:30 -0800

Are you using CFSocket or CFStreams?

With CFSocket, you'll get a return value of zero on your call to recv or read after you've been signaled with the kCFSocketReadCallBack event.

For CFStreams, CFReadStreamRead or CFWriteStreamWrite will return zero. If the end is encountered by the underlying stream implementation prior to read or write on an event-based stream, you would receive a kCFStreamStatusAtEnd event. This of course would only happen if all the bytes had been exhausted from the stream. In other words, you won't receive an end event followed by read/write events.

jeremy

On Dec 6, 2004, at 10:03 PM, Alex Guo wrote:

Hi, All,
 
  How do I know that FD_CLOSE event occurs on a socket ? Anybody can help me?
 
 
Thanks,
Alex
_______________________________________________
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 _______________________________________________
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


References: 
 >FD_CLOSE event occurs on a socket (From: "Alex Guo" <email@hidden>)

  • Prev by Date: Re: Question about CFHTTPMessageAppendBytes
  • Next by Date: Re: the problem with the document about CFHTTPMessageCopyAllHeaderFields
  • Previous by thread: FD_CLOSE event occurs on a socket
  • Next by thread: changing MTU and disable PMTU in MacOS 9
  • Index(es):
    • Date
    • Thread