providers/virtualbox: don't touch DYLD_* anymore.

Subprocess handles this
This commit is contained in:
Mitchell Hashimoto 2013-09-20 17:57:44 -07:00
parent 4d03a7359e
commit 79fa7000fa
1 changed files with 0 additions and 17 deletions

View File

@ -347,26 +347,9 @@ module VagrantPlugins
# Append in the options for subprocess
command << { :notify => [:stdout, :stderr] }
# The following is a workaround for a combined VirtualBox and
# Mac OS X 10.8 bug:
#
# Remove the DYLD_LIBRARY_PATH environmental variable on Mac. This
# is to fix a bug in Mac OS X 10.8 where a warning is printed to the
# console if this is set when executing certain programs, which
# can cause some VBoxManage commands to break because they work
# by just reading stdout and don't expect the OS to just inject
# garbage into it.
old_dyld_lib_path = ENV.delete("DYLD_LIBRARY_PATH")
old_ld_lib_path = ENV.delete("LD_LIBRARY_PATH")
Vagrant::Util::Busy.busy(int_callback) do
Vagrant::Util::Subprocess.execute(@vboxmanage_path, *command, &block)
end
ensure
# Reset the library path if it was set before. See above comments
# for more information on why this was unset in the first place.
ENV["DYLD_LIBRARY_PATH"] = old_dyld_lib_path if old_dyld_lib_path
ENV["LD_LIBRARY_PATH"] = old_ld_lib_path if old_ld_lib_path
end
end
end