diff options
author | kosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-03-16 05:07:28 +0000 |
---|---|---|
committer | kosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-03-16 05:07:28 +0000 |
commit | 92b367e0696785540143707af4093108d6d98c79 (patch) | |
tree | 5826af76d972b089711a751411a8589e2b41e820 /thread.c | |
parent | c824d47ebc829560d022df74d355f69c601ea102 (diff) | |
download | ruby-92b367e0696785540143707af4093108d6d98c79.tar.gz |
* thread.c: disabled _FORTIFY_SOURCE for avoid to hit glibc bug.
[Bug #8080] [ruby-core:53349]
* test/ruby/test_io.rb (TestIO#test_io_select_with_many_files):
test for the above.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39775 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread.c')
-rw-r--r-- | thread.c | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -42,6 +42,19 @@ */ +/* + * FD_SET, FD_CLR and FD_ISSET have a small sanity check when using glibc + * 2.15 or later and set _FORTIFY_SOURCE > 0. + * However, the implementation is wrong. Even though Linux's select(2) + * support large fd size (>FD_SETSIZE), it wrongly assume fd is always + * less than FD_SETSIZE (i.e. 1024). And then when enabling HAVE_RB_FD_INIT, + * it doesn't work correctly and makes program abort. Therefore we need to + * disable FORTY_SOURCE until glibc fixes it. + */ +#undef _FORTIFY_SOURCE +#undef __USE_FORTIFY_LEVEL +#define __USE_FORTIFY_LEVEL 0 + /* for model 2 */ #include "eval_intern.h" |