Fixed bug when run under jruby. open3 seems to be broken