次のようにすると core を吐きます。

% ./ruby -rio/nonblock -e '
str = "a" * 0x20000
STDOUT.nonblock = true
Thread.new { Thread.pass; str.clear }
STDOUT.write str'| sleep 1
-e:5: [BUG] Segmentation fault
ruby 1.9.0 (2004-10-30) [i686-linux]

zsh: abort (core dumped)  ./ruby -rio/nonblock -e  | 
zsh: done                 sleep 1
% gdb ruby core 
GNU gdb 6.1-debian
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-linux"...Using host libthread_db library "/lib/libthread_db.so.1".

Core was generated by `./ruby -rio/nonblock -e 
str = "a" * 0x20000
STDOUT.nonblock = true
Thread.new'.
Program terminated with signal 6, Aborted.
Reading symbols from /lib/libdl.so.2...done.
Loaded symbols for /lib/libdl.so.2
Reading symbols from /lib/libcrypt.so.1...done.
Loaded symbols for /lib/libcrypt.so.1
Reading symbols from /lib/libm.so.6...done.
Loaded symbols for /lib/libm.so.6
Reading symbols from /lib/libc.so.6...done.
Loaded symbols for /lib/libc.so.6
Reading symbols from /lib/ld-linux.so.2...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /home/akr/ruby/head-ruby/lib/ruby/1.9/i686-linux/fcntl.so...done.
Loaded symbols for /home/akr/ruby/head-ruby/lib/ruby/1.9/i686-linux/fcntl.so
#0  0x4009e6b1 in kill () from /lib/libc.so.6
(gdb) bt
#0  0x4009e6b1 in kill () from /lib/libc.so.6
#1  0x4009e435 in raise () from /lib/libc.so.6
#2  0x4009f978 in abort () from /lib/libc.so.6
#3  0x080d4136 in rb_bug (fmt=0x0) at error.c:214
#4  0x080b14d2 in sigsegv (sig=11) at signal.c:446
#5  <signal handler called>
#6  0x400ec45d in mempcpy () from /lib/libc.so.6
#7  0x400e05d1 in _IO_file_xsputn () from /lib/libc.so.6
#8  0x400d59af in fwrite () from /lib/libc.so.6
#9  0x080762b2 in rb_io_fwrite (ptr=0x401da008 <Address 0x401da008 out of bounds>, len=131072, f=0x4019e080) at io.c:415
#10 0x08076399 in io_write (io=135462120, str=1075605336) at io.c:476
#11 0x0806a502 in call_cfunc (func=0x8076310 <io_write>, recv=1075634176, len=1073848320, argc=1024, argv=0xbffff138)
    at eval.c:5379
#12 0x0805e417 in rb_call0 (klass=1075636716, recv=1075634176, id=7321, oid=4096, argc=1, argv=0xbffff138, 
    body=0x401ce44c, nosuper=0) at eval.c:5523
#13 0x0805e6c8 in rb_call (klass=1075636716, recv=1075634176, mid=7321, argc=1, argv=0xbffff138, scope=0) at eval.c:5744
#14 0x08059538 in rb_eval (self=1075673536, n=0x1000) at ruby.h:633
#15 0x080559ad in ruby_exec_internal () at eval.c:1457
#16 0x080559c6 in ruby_exec () at eval.c:1475
#17 0x08055a10 in ruby_run () at eval.c:1492
#18 0x08053a15 in main (argc=4096, argv=0x1000, envp=0xbffff928) at main.c:38
(gdb) 
-- 
[田中 哲][たなか あきら][Tanaka Akira]