diff options
author | Thomas E. Dickey <dickey@invisible-island.net> | 2001-06-11 01:14:52 -0400 |
---|---|---|
committer | Thomas E. Dickey <dickey@invisible-island.net> | 2001-06-11 01:14:52 -0400 |
commit | 244151ea1ed7b05051bd92a653bbde57c8194061 (patch) | |
tree | 13b8c5ac42c66347c61173e7d5929f738374b006 /WWW/Library/Implementation/www_tcp.h | |
parent | 1f734c80c35ae04b3e8b0b82707d643f52852c6d (diff) | |
download | lynx-snapshots-244151ea1ed7b05051bd92a653bbde57c8194061.tar.gz |
snapshot of project "lynx", label v2-8-4pre_2
Diffstat (limited to 'WWW/Library/Implementation/www_tcp.h')
-rw-r--r-- | WWW/Library/Implementation/www_tcp.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/WWW/Library/Implementation/www_tcp.h b/WWW/Library/Implementation/www_tcp.h index 9de8ea51..f3f5ac65 100644 --- a/WWW/Library/Implementation/www_tcp.h +++ b/WWW/Library/Implementation/www_tcp.h @@ -830,6 +830,10 @@ typedef struct sockaddr_in SockA; /* See netinet/in.h */ #ifdef SIN6_LEN #define SOCKADDR_LEN(soc_address) ((struct sockaddr *)&soc_address)->sa_len #else +#ifndef SA_LEN +#define SA_LEN(x) (((x)->sa_family == AF_INET6)?sizeof(struct sockaddr_in6): \ + (((x)->sa_family == AF_INET)?sizeof(struct sockaddr_in):sizeof(struct sockaddr))) +#endif #define SOCKADDR_LEN(soc_address) SA_LEN((struct sockaddr *)&soc_address) #endif /* SIN6_LEN */ #else |