Re: why does this code NOT work on macbookpro? SOLVED
Re: why does this code NOT work on macbookpro? SOLVED
- Subject: Re: why does this code NOT work on macbookpro? SOLVED
- From: Perry Winkel <email@hidden>
- Date: Sun, 17 Sep 2006 20:58:15 +0200
twas an endian thing
used htons to convert the port number and inet_aton for the address
things looking much better now! On Sep 17, 2006, at 8:10 PM, Henri Asseily wrote:
On Sep 17, 2006, at 6:02 PM, Clark Cox wrote:
You need some htons calls in there (remember that network order is big-endian). See:
man byteorder
If you know that client and server have the same endianness, it works. If you're not sure, you need to convert everything to network-endian and back. Network-endian is defined to be big-endian, so on PPC these are no-ops.
H
-- met vriendelijke groeten perry winkel
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden