• 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: CFSocketDataCallBack buffer size
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CFSocketDataCallBack buffer size


  • Subject: Re: CFSocketDataCallBack buffer size
  • From: Aram Greenman <email@hidden>
  • Date: Mon, 23 Sep 2002 19:13:54 -0700

On Monday, September 23, 2002, at 02:16 PM, Douglas Davidson wrote:

With kCFSocketDataCallBack, CFSocket will usually try to read as much as it can get in a single read(), up to some internal limit. It does not wait until a certain amount of data is available. You may wish to try using kCFSocketReadCallBack instead, and do the read() yourself, if you do not like what you are getting from kCFSocketDataCallBack. However, if you are using a stream-oriented socket, in general you should not expect packet boundaries to be evident, no matter what API you are using.

I meant application layer 'packets', I guess I should have said 'messages'.
Anyway I am now using kCFSocketReadCallBack and storing the data in a buffer until a complete message is read and issuing my own callback at that time, which is working fine.

Thanks,
Aram
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: CFSocketDataCallBack buffer size (From: Douglas Davidson <email@hidden>)

  • Prev by Date: Re: OTRcv when disconnected
  • Next by Date: Re: disabling mulicast loopback + getting IP
  • Previous by thread: Re: CFSocketDataCallBack buffer size
  • Next by thread: Re: OTRcv when disconnected
  • Index(es):
    • Date
    • Thread