Re: CFNetwork port to Intel
Re: CFNetwork port to Intel
- Subject: Re: CFNetwork port to Intel
- From: Jeff Heyob <email@hidden>
- Date: Fri, 29 Jun 2007 10:34:52 -0400
Fred,
Thanks for looking at my code.
It looks like I need more sleep.
The first thing that I saw in your reply was your change of my
BigToHost into HostToBig.
It took me a couple more looks to see the 32 that I had mistakenly used.
Thanks for the catch!
It is working now.
Thanks,
Jeff
On Jun 29, 2007, at 9:45 AM, Frederick Cheung wrote:
On 29 Jun 2007, at 14:30, Jeff Heyob wrote:
Hi,
I have CFNework code that sets up a listening socket to accept
incoming connection requests. It has been working fine when built
against sdk10.3 using Xcode 2.4.1. I recently ported the
supporting app to Intel against sdk10.4. The PPC built of the
CFNetwork code works fine , but the Intel CFNetwork code doesn't
respond to any connection requests.
Here is the code. The "OpenListener" code executes with no error.
There is no response to connection requests in the "ServerCall"
code. I've tried the listenPort integer as both little and big
endian with no luck.
I would really appreciate any help to get this to work on Intel.
Thanks,
Jeff
struct sockaddr_in addrs = {8,AF_INET,CFSwapInt32BigToHost
(listenPort),{0}};
ports are 16 bit things, so you need htons or CFSwapInt16HostToBig,
not CFSwapInt32HostToBig
Incidentally lsof is good for checking if your code is listening on
the port you think it is.
Fred
_______________________________________________
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