From cb67e0bd9c4382b916e7b2401bfbe7b01786da1c Mon Sep 17 00:00:00 2001 From: kazu Date: Mon, 30 Apr 2018 10:01:08 +0000 Subject: [PATCH] Use `&.` instead of modifier if git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63306 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/open3.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/open3.rb b/lib/open3.rb index 2bbead2951..df34e2c9ce 100644 --- a/lib/open3.rb +++ b/lib/open3.rb @@ -657,8 +657,8 @@ module Open3 end pid = spawn(*cmd, cmd_opts) wait_thrs << Process.detach(pid) - r.close if r - w2.close if w2 + r&.close + w2&.close r = r2 } result = parent_io + [wait_thrs]