Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet_aton.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet_aton.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet_aton.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet_aton.html on line 8

inet_aton()

Convert a string into an Internet address stored in a structure

Synopsis:

#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>

int inet_aton( const char * cp,
               struct in_addr * addr );

Arguments:

cp
A pointer to the character string.
addr
A pointer to a in_addr structure where the function can store the converted address.

Library:

libsocket

Use the -l socket option to qcc to link against this library.

Description:

The inet_aton() routine interprets the specified character string as an IPv4 Internet address, placing the address into the structure provided.

All Internet addresses are returned in network byte order (bytes are ordered from left to right). All network numbers and local address parts are returned as machine-format integer values.

For more information on Internet addresses, see inet_net_ntop().

Returns:

1
Success; the string was successfully interpreted.
0
Failure; the string is invalid.

Classification:

Unix

Safety:
Cancellation point No
Interrupt handler No
Signal handler Yes
Thread Yes

See also:

gethostbyname(), getnetent() inet_addr(), inet_lnaof(), inet_makeaddr(), inet_netof(), inet_network(), inet_ntoa()

/etc/hosts, /etc/networks in the Utilities Reference


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet_aton.html on line 150

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/i/inet_aton.html on line 150