From bb25bb3be9c7a7fc0424680c55ece469fa7362dd Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Mon, 6 Jul 2015 14:39:50 -0600 Subject: [PATCH] core: actually get the proper encoded subprocess command [GH-5128] --- lib/vagrant/util/subprocess.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/vagrant/util/subprocess.rb b/lib/vagrant/util/subprocess.rb index 278d68d01..e249b72c1 100644 --- a/lib/vagrant/util/subprocess.rb +++ b/lib/vagrant/util/subprocess.rb @@ -25,7 +25,7 @@ module Vagrant def initialize(*command) @options = command.last.is_a?(Hash) ? command.pop : {} @command = command.dup - @command.each { |s| s.encode(Encoding.default_external) } + @command = @command.map { |s| s.encode(Encoding.default_external) } @command[0] = Which.which(@command[0]) if !File.file?(@command[0]) if !@command[0] raise Errors::CommandUnavailableWindows, file: command[0] if Platform.windows?