socket/pure_ruby: fix Ruby 1.8 compatibility
commit304d878e81ca90762346f1842adc0387160c5ad9
authorEric Wong <e@80x24.org>
Thu, 22 Oct 2015 22:26:23 +0000 (22 22:26 +0000)
committerEric Wong <e@80x24.org>
Thu, 22 Oct 2015 22:26:23 +0000 (22 22:26 +0000)
treea7353d561ab772c3568e3f57dfa0c2cd6f79b300
parent89cf206bb5b30dc1f5ef17946c6a96ce957a302d
socket/pure_ruby: fix Ruby 1.8 compatibility

For non-kgio users, IO#wait_readable did not appear until Ruby 2.0.
Additionally, optimistically perform reads before waiting because
EOF handling behavior differs in current revisions of Ruby 2.3.0dev.
lib/mogilefs/socket/pure_ruby.rb