fix #339 also in IO.rb
whitespace fixes