Out of curiosity, I compiled our test environment
with the htons call on the sin_family on i386/Linux
which resulted in the connection error:

#define EAFNOSUPPORT 97 /* Address family not supported by protocol */

Which is what I suppose you would expect ;)

Ken Hornstein wrote:
#if defined(AFS_DARWIN_ENV) || defined(AFS_FBSD_ENV)
            curr_skt->sin_family = AF_INET;          /*Internet family */
#else
            curr_skt->sin_family = htons(AF_INET);   /*Internet family */
#endif

I suspect that this code is wrong and the address family should always be
given in host order.  This just happens to work on sun and aix because they
run on big-endian processors.  Not sure about linux.

I think you're right; I don't think I've ever seen anyone ever use
htons on the address family.

--Ken
_______________________________________________
OpenAFS-devel mailing list
[email protected]
https://lists.openafs.org/mailman/listinfo/openafs-devel



--
Mr. Kristen J. Webb
Teradactyl LLC.

PHONE: 1-505-242-1091
EMAIL: [EMAIL PROTECTED]
VISIT: http://www.teradactyl.com

        Home of the

 True incremental Backup System

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to