*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> ntohl (9r)              
Title
Content
Arch
Section
 

ntohl(9r)

Contents


NAME    [Toc]    [Back]

       ntohl,  ntohs  - General: Convert longword and word values
       from network-to-host byte order

SYNOPSIS    [Toc]    [Back]

       #include <sys/param.h>

       unsigned int ntohl(
               unsigned int longword ); unsigned short ntohs(
               unsigned short word );

ARGUMENTS    [Toc]    [Back]

       Specifies a 32-bit value to be conditionally byte swapped.
       Specifies a 16-bit value to be conditionally byte swapped.

DESCRIPTION    [Toc]    [Back]

       The ntohl routine converts the  specified  longword  value
       from  network-to-host  byte  order. The ntohs routine converts
 the specified word value from  network-to-host  byte
       order.

       The  TCP/IP  protocols  specify the canonical network byte
       order, which is big endian (meaning that the most significant
 byte is leftmost in memory).

RETURN VALUES    [Toc]    [Back]

       Upon  successful completion, the ntohl routine returns the
       converted longword value in host  byte  order.  Similarly,
       upon  successful completion, the ntohs routine returns the
       converted word value in host byte order.

SEE ALSO    [Toc]    [Back]

      
      
       Routines: htonl(9r)



                                                        ntohl(9r)
[ Back ]
 Similar pages
Name OS Title
htonl Tru64 General: Convert word and longword values
htons Tru64 General: Convert word and longword values
suword Tru64 General: Writes a word into user address space
fuiword Tru64 General: Returns a word from user instruction address space
fuword Tru64 General: Returns a word from user instruction address space
suiword Tru64 General: Writes a word into user instruction address space
htole32 OpenBSD convert values between different byte orderings
htole64 OpenBSD convert values between different byte orderings
htonl OpenBSD convert values between different byte orderings
betoh16 OpenBSD convert values between different byte orderings
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service