summaryrefslogtreecommitdiff
path: root/ext/socket/extconf.rb
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-10-18 09:03:16 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-10-18 09:03:16 +0000
commit125ca1a11a53810ac311012352f5b0773fc2bbde (patch)
tree2b9ac558373e9742e475be19fed72bfb7924a0f9 /ext/socket/extconf.rb
parent40a3f601e43a137e56b2c28454ffb6ce79d7ec7e (diff)
19991018
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@546 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/socket/extconf.rb')
-rw-r--r--ext/socket/extconf.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/ext/socket/extconf.rb b/ext/socket/extconf.rb
index 47addfeff8..467c052a85 100644
--- a/ext/socket/extconf.rb
+++ b/ext/socket/extconf.rb
@@ -160,6 +160,10 @@ if try_run(<<EOF)
#include <sys/socket.h>
#include <netinet/in.h>
+#ifndef AF_LOCAL
+#define AF_LOCAL AF_UNIX
+#endif
+
main()
{
int passive, gaierr, inet4 = 0, inet6 = 0;
@@ -176,6 +180,7 @@ main()
goto bad;
}
for (ai = aitop; ai; ai = ai->ai_next) {
+ if (ai->ai_family == AF_LOCAL) continue;
if (ai->ai_addr == NULL ||
ai->ai_addrlen == 0 ||
getnameinfo(ai->ai_addr, ai->ai_addrlen,