From e547b263099bd2d7f55cd1fe1ee85d96b7bd70d0 Mon Sep 17 00:00:00 2001 From: slackfan Date: Fri, 7 Sep 2018 09:27:01 +0200 Subject: [PATCH] Don't compare paths by String The implemented String comparison is misleading on Windows as it does not consider that paths on Windows are case insensitive Signed-off-by: Alexander Fischer --- lib/vagrant/machine.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/vagrant/machine.rb b/lib/vagrant/machine.rb index 88ef368bd..f7f190d63 100644 --- a/lib/vagrant/machine.rb +++ b/lib/vagrant/machine.rb @@ -4,6 +4,7 @@ require "digest/md5" require "thread" require "log4r" +require "vagrant/util/platform" module Vagrant # This represents a machine that Vagrant manages. This provides a singular @@ -593,7 +594,7 @@ module Vagrant ).chomp end - if vagrant_cwd != @env.root_path.to_s + if !File.identical?(vagrant_cwd.to_s, @env.root_path.to_s) if vagrant_cwd ui.warn(I18n.t( 'vagrant.moved_cwd',