• 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
Sending data with CFSocket
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Sending data with CFSocket


  • Subject: Sending data with CFSocket
  • From: Tomas Franzén <email@hidden>
  • Date: Tue, 28 Jun 2005 15:13:54 +0200

Hi,

I'm using CFSocket to connect/listen for connections and it works pretty great.
But I do have a problem sending data. If I call CFSocketSendData several times (in a row, basically), it often seems like some data gets truncated. Is this because CFSocket doesn't have enough time to send data before I send some more?

I tried 'subscribing' to the kCFSocketWriteCallBack callback, and ran a run loop with a timer checking if that callback had been called, and if so, stop the loop. But the callback never fired until the main app loop ran (I'm writing a plug-in so I don't have control over the main app).

What's the best way to solve this? Can I somehow wait for CFSocket to finish sending before continuing?

If someone could point me in the correct direction, or give me some sample code, that would be great.
Thanks,

Tomas Franzén

Lighthead Software

http://www.lightheadsw.com/

 _______________________________________________
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: Sending data with CFSocket
      • From: Douglas Davidson <email@hidden>
  • Prev by Date: Re: attached gateways [MORE_QUESTIONS...]
  • Next by Date: Re: attached gateways
  • Previous by thread: Re: PPPoE Section in AirPort ?
  • Next by thread: Re: Sending data with CFSocket
  • Index(es):
    • Date
    • Thread