summaryrefslogtreecommitdiff
path: root/ext/socket/sockport.h
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-02-14 22:08:28 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-02-14 22:08:28 +0000
commit4faef960f2e198fd3158bcaf7e37b015c9a6e7a2 (patch)
tree03391d578776d8844fb9038e9517e7ded80f37b8 /ext/socket/sockport.h
parente4b775882d8eb458342a827c9decc68db63c10eb (diff)
* ext/socket/sockport.h (SA_LEN): removed because unused now.
(SS_LEN): ditto. (SIN_LEN): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39246 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/socket/sockport.h')
-rw-r--r--ext/socket/sockport.h24
1 files changed, 0 insertions, 24 deletions
diff --git a/ext/socket/sockport.h b/ext/socket/sockport.h
index 43784fc..1e01bce 100644
--- a/ext/socket/sockport.h
+++ b/ext/socket/sockport.h
@@ -16,28 +16,6 @@
# define VALIDATE_SOCKLEN(addr, len) ((void)(addr), (void)(len), 1)
#endif
-#ifdef SA_LEN
-# define SS_LEN(ss) (ss)->ss_len
-#else
-# ifdef HAVE_STRUCT_SOCKADDR_SA_LEN
-# define SA_LEN(sa) (sa)->sa_len
-# define SS_LEN(ss) (ss)->ss_len
-# else
-# ifdef AF_INET6
-# define SA_LEN(sa) \
- (((sa)->sa_family == AF_INET6) ? sizeof(struct sockaddr_in6) \
- : sizeof(struct sockaddr))
-# define SS_LEN(ss) \
- (((ss)->ss_family == AF_INET6) ? sizeof(struct sockaddr_in6) \
- : sizeof(struct sockaddr))
-# else
- /* by tradition, sizeof(struct sockaddr) covers most of the sockaddrs */
-# define SA_LEN(sa) (sizeof(struct sockaddr))
-# define SS_LEN(ss) (sizeof(struct sockaddr))
-# endif
-# endif
-#endif
-
#ifdef HAVE_STRUCT_SOCKADDR_SA_LEN
# define SET_SA_LEN(sa, len) (void)((sa)->sa_len = (len))
# define SET_SS_LEN(ss, len) (void)((ss)->ss_len = (len))
@@ -47,10 +25,8 @@
#endif
#ifdef HAVE_STRUCT_SOCKADDR_IN_SIN_LEN
-# define SIN_LEN(si) (si)->sin_len
# define SET_SIN_LEN(si,len) (si)->sin_len = (len)
#else
-# define SIN_LEN(si) sizeof(struct sockaddr_in)
# define SET_SIN_LEN(si,len)
#endif