ntohl()

The ntohl() call translates a long integer from network-byte order to host-byte order.

Syntax

#include <types.h>
u_long ntohl(a)
u_long a;

Parameters

a

Description

This call translates a long integer from network-byte order to host-byte order. Receiving hosts require addresses and ports in host-byte order. Use the ntohl() call to convert internet addresses to the host integer representation.

Return Values

Returns the translated long integer.

Related Calls


[Back: inet_ntoa()]
[Next: ntohs()]