diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2008-07-06 11:16:23 +0000 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2008-07-06 11:16:23 +0000 |
| commit | c45e044b22aba55047eeb50f73cd894bc20a0a13 (patch) | |
| tree | 505e7007e6a2c296a453edb6dc2e448128f07940 | |
| parent | cfa808126b37d24944bc817972079b333c4cf8a1 (diff) | |
2008-07-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the compile error on Nexenta OS(GNU/Solaris OS).
Don't define `struct addrinfo' when __sun is defined.
* src/getaddrinfo.h
| -rw-r--r-- | ChangeLog | 6 | ||||
| -rw-r--r-- | src/getaddrinfo.h | 9 |
2 files changed, 11 insertions, 4 deletions
@@ -1,5 +1,11 @@ 2008-07-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com> + Fixed the compile error on Nexenta OS(GNU/Solaris OS). + Don't define `struct addrinfo' when __sun is defined. + * src/getaddrinfo.h + +2008-07-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com> + Introduced a2_struct_stat. It is defined as `struct _stati64' if __MINGW32__ is defined, because under MinGW32, _stati64 is used and its second argument is of type `struct _stati64'. Otherwise it is defined as diff --git a/src/getaddrinfo.h b/src/getaddrinfo.h index 1aa9a2d8..d3d91564 100644 --- a/src/getaddrinfo.h +++ b/src/getaddrinfo.h @@ -161,7 +161,7 @@ extern "C" { #define getnameinfo my_getnameinfo #endif -# <from linux's netdb.h> +/* <from linux's netdb.h> */ /* Possible values for `ai_flags' field in `addrinfo' structure. */ # define AI_PASSIVE 0x0001 /* Socket address is intended for `bind'. */ # define AI_CANONNAME 0x0002 /* Request for canonical name. */ @@ -219,7 +219,7 @@ extern "C" { # define NI_IDN_USE_STD3_ASCII_RULES 128 /* Validate strings according to STD3 rules. */ # endif -# </from linux's netdb.h> +/* </from linux's netdb.h> */ #define AI_DEFAULT (AI_V4MAPPED | AI_ADDRCONFIG) @@ -233,7 +233,8 @@ extern "C" { #define PF_UNSPEC PF_INET #endif -#ifndef __MINGW32__ +/* Nexenta OS(GNU/Solaris OS) defines `struct addrinfo' in netdb.h */ +#if !defined( __MINGW32__ ) && !defined( __sun ) /* * struct addrinfo. @@ -249,7 +250,7 @@ struct addrinfo { struct addrinfo *ai_next; }; -#endif // __MINGW32__ +#endif // !__MINGW32__ && !__sun /* * Functions. |
