Go to the source code of this file.
Data Structures | |
| struct | hostent |
| Resolver host structure. More... | |
Defines | |
| #define | _ABLE_CLIB_NETDB_H 1 |
| #define | NETDB_INTERNAL -1 |
| Value for h_errno meaning internal error, see errno. | |
| #define | NETDB_SUCCESS 0 |
| Value for h_errno meaning success. | |
| #define | HOST_NOT_FOUND 1 |
| Value for h_errno meaning 'host not found'. | |
| #define | TRY_AGAIN 2 |
| Value for h_errno meaning 'non-authoritative failure'. | |
| #define | NO_RECOVERY 3 |
| Value for h_errno meaning 'unrecoverable error'. | |
| #define | NO_DATA 4 |
| Value for h_errno meaning 'no data of requested type found'. | |
| #define | NO_ADDRESS NO_DATA |
| #define | h_addr h_addr_list[0] |
| #define | sethostent(stayopen) |
| #define | endhostent() |
Functions | |
| struct hostent * | gethostbyname (const char *name) |
| Look up a host by name and return a hostent structure. | |
| struct hostent * | gethostbyaddr (const void *addr, socklen_t len, int type) |
| Look up a host by address and return a hostent structure. | |
| void | herror (const char *s) |
| Print the error in h_errno to stderr. | |
| const char * | hstrerror (int err) |
| Return a pointer to a static string representing err. | |
Variables | |
| int | h_errno |
| Equivalent of errno for gethostbyname etc. | |
| #define _ABLE_CLIB_NETDB_H 1 |
| #define endhostent | ( | ) |
| #define h_addr h_addr_list[0] |
| #define HOST_NOT_FOUND 1 |
Value for h_errno meaning 'host not found'.
| #define NETDB_SUCCESS 0 |
Value for h_errno meaning success.
| #define NO_ADDRESS NO_DATA |
| #define NO_DATA 4 |
Value for h_errno meaning 'no data of requested type found'.
| #define NO_RECOVERY 3 |
Value for h_errno meaning 'unrecoverable error'.
| #define sethostent | ( | stayopen | ) |
| #define TRY_AGAIN 2 |
Value for h_errno meaning 'non-authoritative failure'.
Look up a host by address and return a hostent structure.
| addr | The address to look up. | |
| len | The length of the address to look up. | |
| type | The type (E.g. AF_INET) of the address to look up. |
| struct hostent* gethostbyname | ( | const char * | name | ) | [read] |
Look up a host by name and return a hostent structure.
| name | The DNS name to lookup. |
| const char* hstrerror | ( | int | err | ) |
Return a pointer to a static string representing err.
| int h_errno |
Equivalent of errno for gethostbyname etc.
1.5.6