• 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
Why might CFReadStreamCopyProperty(stream, kCFStreamPropertySocketNativeHandle) return NULL?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Why might CFReadStreamCopyProperty(stream, kCFStreamPropertySocketNativeHandle) return NULL?


  • Subject: Why might CFReadStreamCopyProperty(stream, kCFStreamPropertySocketNativeHandle) return NULL?
  • From: Michael Ledford <email@hidden>
  • Date: Fri, 29 Aug 2008 01:55:29 -0400

Hello,

Currently I am working on a client that makes REST HTTP calls.

I decided I wanted to use persistent HTTP connections so I am working with CFReadStreamCreateForHTTPRequest() with the appropriate properties set on the CFReadStream to achieve that. I have the need to get at the native socket handle from the CFFReadStream but I am finding that CFReadStreamCopyProperty(stream, kCFStreamPropertySocketNativeHandle) sometimes returns NULL even though the CFReadStream has been opened, the status reports that it is open, and the client callback kCFStreamEventOpenCompleted has been issued.

The documentation makes no mention under what circumstances, if any, this will occur. The only thing out of the ordinary in the way my code is handled is the CFReadStreamOpen() is called from a timer.

Can someone give me some clear direction as to why this is occurring?

Thank you,
Michael


_______________________________________________ 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: Why might CFReadStreamCopyProperty(stream, kCFStreamPropertySocketNativeHandle) return NULL?
      • From: Quinn <email@hidden>
  • Prev by Date: Re: How to get the local Bonjour name?
  • Next by Date: Re: CFHTTPMessage and thread safety
  • Previous by thread: Re: How to get the local Bonjour name?
  • Next by thread: Re: Why might CFReadStreamCopyProperty(stream, kCFStreamPropertySocketNativeHandle) return NULL?
  • Index(es):
    • Date
    • Thread