Skip to content

Commit

Permalink
Use #gets rather than #read to read from pipe in System#call
Browse files Browse the repository at this point in the history
This solves the issue with indefinite-blocking when trying to get the
Chromium version packaged via snap on Debian/Ubuntu, mentioned in titusfortner#168
  • Loading branch information
nickgrim authored and kapoorlakshya committed May 23, 2020
1 parent a50315e commit ea64bf5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/webdrivers/system.rb
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ def call(process, arg = nil)
cmd = arg ? [process, arg] : process # Windows provides powershell command (process) only, no args.
Webdrivers.logger.debug "making System call: #{cmd}"
p = IO.popen(cmd)
out = p.read
out = p.gets
p.close
raise "Failed to make system call: #{cmd}" unless $CHILD_STATUS.success?

Expand Down

0 comments on commit ea64bf5

Please sign in to comment.