mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-30 23:53:32 +01:00
Apparently, our windows code for detecting ipv6 structures has worked for a while. Remove the special-case, remove the related XXXX020s, and add useful comments instead.
svn:r13377
This commit is contained in:
parent
c397c64d15
commit
54029559d7
@ -271,8 +271,11 @@ int get_n_open_sockets(void);
|
|||||||
typedef int socklen_t;
|
typedef int socklen_t;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* XXXX020 detect in6_addr correctly on ms_windows; this is a hack. */
|
/* Define struct in6_addr on platforms that do not have it. Generally,
|
||||||
#if !defined(HAVE_STRUCT_IN6_ADDR) && !defined(MS_WINDOWS)
|
* these platforms are ones without IPv6 support, but we want to have
|
||||||
|
* a working in6_addr there anyway, so we can use it to parse IPv6
|
||||||
|
* addresses. */
|
||||||
|
#if !defined(HAVE_STRUCT_IN6_ADDR)
|
||||||
struct in6_addr
|
struct in6_addr
|
||||||
{
|
{
|
||||||
union {
|
union {
|
||||||
@ -313,8 +316,9 @@ typedef uint16_t sa_family_t;
|
|||||||
#define S6_ADDR16(x) ((uint16_t*)((char*)&(x).s6_addr))
|
#define S6_ADDR16(x) ((uint16_t*)((char*)&(x).s6_addr))
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* XXXX020 detect sockaddr_in6 correctly on ms_windows; this is also a hack. */
|
/* Define struct sockaddr_in6 on platforms that do not have it. See notes
|
||||||
#if !defined(HAVE_STRUCT_SOCKADDR_IN6) && !defined(MS_WINDOWS)
|
* on struct in6_addr. */
|
||||||
|
#if !defined(HAVE_STRUCT_SOCKADDR_IN6)
|
||||||
struct sockaddr_in6 {
|
struct sockaddr_in6 {
|
||||||
sa_family_t sin6_family;
|
sa_family_t sin6_family;
|
||||||
uint16_t sin6_port;
|
uint16_t sin6_port;
|
||||||
|
Loading…
Reference in New Issue
Block a user