summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authoryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-07-10 04:06:05 +0000
committeryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-07-10 04:06:05 +0000
commitf813b7dc1a34800bb675ffd83d6d05013b10c5d8 (patch)
tree494889c5acb2ec85399e081a68d83b478d9c396e /include
parentaa1fdb90530fb9d440ab2eae182bf085f1ca2570 (diff)
merges r28561 from trunk into ruby_1_9_2.
-- * missing/close.c: ignore ECONNRESET. FreeBSD wrongly sets ECONNRESET on close(2) and it causes false-negative exceptions. [ruby-dev:41778] * configure.in: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_2@28604 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include')
-rw-r--r--include/ruby/ruby.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h
index ff4912847e..5ed6f3da1c 100644
--- a/include/ruby/ruby.h
+++ b/include/ruby/ruby.h
@@ -1421,6 +1421,17 @@ int ruby_vsnprintf(char *str, size_t n, char const *fmt, va_list ap);
#define snprintf ruby_snprintf
#define vsnprintf ruby_vsnprintf
+#ifdef __FreeBSD__
+#undef getpeername
+#define getpeername ruby_getpeername
+#undef getsockname
+#define getsockname ruby_getsockname
+#undef shutdown
+#define shutdown ruby_shutdown
+#undef close
+#define close ruby_close
+#endif
+
#if defined(__cplusplus)
#if 0
{ /* satisfy cc-mode */