4.3BSD-Reno/share/man/cat3/htons.0

Compare this file to the similar file:
Show the results in this format:




BYTEORDER(3)		      1990		     BYTEORDER(3)



NNAAMMEE
     htonl, htons, ntohl, ntohs - convert values between host and
     network byte order

SSYYNNOOPPSSIISS
     ##iinncclluuddee <<mmaacchhiinnee//eennddiiaann..hh>>

     nneettlloonngg == hhttoonnll((hhoossttlloonngg));;
     uu__lloonngg nneettlloonngg,, hhoossttlloonngg;;

     nneettsshhoorrtt == hhttoonnss((hhoossttsshhoorrtt));;
     uu__sshhoorrtt nneettsshhoorrtt,, hhoossttsshhoorrtt;;

     hhoossttlloonngg == nnttoohhll((nneettlloonngg));;
     uu__lloonngg hhoossttlloonngg,, nneettlloonngg;;

     hhoossttsshhoorrtt == nnttoohhss((nneettsshhoorrtt));;
     uu__sshhoorrtt hhoossttsshhoorrtt,, nneettsshhoorrtt;;

DDEESSCCRRIIPPTTIIOONN
     These routines convert 16 and 32 bit quantities between net-
     work byte order and host byte order.  On machines such as
     the SUN these routines are defined as null macros in the
     include file <_n_e_t_i_n_e_t/_i_n._h>.

     These routines are most often used in conjunction with
     Internet addresses and ports as returned by _g_e_t_h_o_s_t_b_y_n_a_m_e(3)
     and _g_e_t_s_e_r_v_e_n_t(3).

SSEEEE AALLSSOO
     gethostbyname(3), getservent(3)

BBUUGGSS
     The VAX handles bytes backwards from most everyone else in
     the world.  This is not expected to be fixed in the near
     future.



















Printed 7/27/90               June				1