From owner-freebsd-chat Tue Oct 23 10:33:46 2001 Delivered-To: freebsd-chat@freebsd.org Received: from web11508.mail.yahoo.com (web11508.mail.yahoo.com [216.136.172.40]) by hub.freebsd.org (Postfix) with SMTP id 7143637B40C for ; Tue, 23 Oct 2001 10:33:44 -0700 (PDT) Message-ID: <20011023173344.11999.qmail@web11508.mail.yahoo.com> Received: from [200.68.128.83] by web11508.mail.yahoo.com via HTTP; Tue, 23 Oct 2001 10:33:44 PDT Date: Tue, 23 Oct 2001 10:33:44 -0700 (PDT) From: Fabio Miranda Subject: Socket help To: freebsd-chat@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-chat@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Hi, i am student of system engineering and I have been studying socket system for a subject at university. I have found much difficult understanding the functions: htonl(u_long hostlong); htons(u_short hostshort); ntohl(u_long netlong); ntohs(u_short netshort); I dont understand: What are they for?, What structure do they recive and what they return? how an ip address is stored in a struct ? each part is threat as int or the whole is an char? as you can see, i am very confused i appreciate your help, i have found lots of online documentation but I wish to know what's happening inside, how to deal the structures: sockaddr_in, hostent, etc thanks, thanks alot!. The result of this research is a publication in a local magazine, freebsd is alive in south america!!! __________________________________________________ Do You Yahoo!? Make a great connection at Yahoo! Personals. http://personals.yahoo.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-chat" in the body of the message