event_machine: protect IO#close from EBADF
commit41d9de49f9adf49b50b034ece6ea5a58688a6cce
authorEric Wong <normalperson@yhbt.net>
Mon, 2 Aug 2010 04:52:21 +0000 (2 04:52 +0000)
committerEric Wong <normalperson@yhbt.net>
Mon, 2 Aug 2010 04:52:21 +0000 (2 04:52 +0000)
tree19f36d92cbcc03afcd434dbaa5e609d148225dda
parent3a96720e4e0f1d14599b9fae10e210110976e0c5
event_machine: protect IO#close from EBADF

EventMachine may close the underlying file descriptor on us if
there are unrecoverable errors during write.  So IO#closed? is
a pointless check because EM does not invalidate the underlying
file descriptor.
lib/rainbows/event_machine.rb