HTTP response using CFHTTPMessageCreateEmpty/CFHTTPMessageAppendBytes
HTTP response using CFHTTPMessageCreateEmpty/CFHTTPMessageAppendBytes
- Subject: HTTP response using CFHTTPMessageCreateEmpty/CFHTTPMessageAppendBytes
- From: Greg Hoover <email@hidden>
- Date: Sat, 14 Mar 2009 14:17:56 -0700
I'm trying to parse an HTTP Post response using the following code.
The problem is that CFHTTPMessageAppendBytes always returns false.
I've tested by stripping down the response to just "HTTP/1.0 200 OK\r\n
\r\n" and still no go. Does anyone know what the appropriate response
format is?
CFHTTPMessageRef response =
CFHTTPMessageCreateEmpty(kCFAllocatorDefault, TRUE);
if (CFHTTPMessageAppendBytes(response, [data bytes], [data length])) {
if (CFHTTPMessageIsHeaderComplete(response)) {
...
}}
Thanks in advance.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden