Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Revert part of cb4a9c5

Changes to lib/riak/node/console.rb made a mistake about whether to use
invalid pipes.
  • Loading branch information...
commit b5d61f18386d63c1893a5e34c213f26fe6d2c268 1 parent c9f939b
@aphyr aphyr authored
Showing with 10 additions and 7 deletions.
  1. +10 −7 lib/riak/node/console.rb
View
17 lib/riak/node/console.rb
@@ -34,13 +34,16 @@ def initialize(pipedir, nodename)
@prompt = /\(#{Regexp.escape(nodename)}\)\d+>\s*/
pipedir = Pathname(pipedir)
pipedir.children.each do |path|
- debug "Non-pipe found! #{path}" unless path.pipe?
- if path.fnmatch("*.r") # Read pipe
- # debug "Found read pipe: #{path}"
- @rfile ||= path
- elsif path.fnmatch("*.w") # Write pipe
- # debug "Found write pipe: #{path}"
- @wfile ||= path
+ if path.pipe?
+ if path.fnmatch("*.r") # Read pipe
+ # debug "Found read pipe: #{path}"
+ @rfile ||= path
+ elsif path.fnmatch("*.w") # Write pipe
+ # debug "Found write pipe: #{path}"
+ @wfile ||= path
+ end
+ else
+ debug "Non-pipe found! #{path}"
end
end
raise ArgumentError, t('no_pipes', :path => pipedir.to_s) if [@rfile, @wfile].any? {|p| p.nil? }
Please sign in to comment.
Something went wrong with that request. Please try again.