adjust struct hostent for compatibility
This commit is contained in:
parent
39a53c4fe5
commit
6714c04806
@ -9,14 +9,13 @@
|
|||||||
#define TRY_AGAIN 4
|
#define TRY_AGAIN 4
|
||||||
|
|
||||||
struct hostent {
|
struct hostent {
|
||||||
char *h_name;
|
char *h_name; /* official name of host */
|
||||||
char **h_aliases;
|
char **h_aliases; /* alias list */
|
||||||
int h_addrtype;
|
uint16_t h_addrtype; /* host address type */
|
||||||
int h_length;
|
uint16_t h_length; /* length of address */
|
||||||
char **h_addr_list;
|
char **h_addr_list; /* list of addresses from name server */
|
||||||
char *h_addr;
|
|
||||||
};
|
};
|
||||||
|
#define h_addr h_addr_list[0] /* for backward compatibility */
|
||||||
|
|
||||||
#define AI_PASSIVE 0x01
|
#define AI_PASSIVE 0x01
|
||||||
#define AI_CANONNAME 0x02
|
#define AI_CANONNAME 0x02
|
||||||
|
Loading…
Reference in New Issue
Block a user