core: preserve downloaded file in more cases [GH-4301]

This commit is contained in:
Mitchell Hashimoto 2014-08-06 11:23:02 -07:00
parent 00bd226fc7
commit 145af54cec
2 changed files with 2 additions and 4 deletions

View File

@ -19,6 +19,8 @@ IMPROVEMENTS:
BUG FIXES:
- core: Downloading box files should resume in more cases since the
temporary file is preserved in more cases. [GH-4301]
- core: Windows is not detected as NixOS in some cases. [GH-4302]
- core: Fix encoding issues with Windows. There are still some outlying
but this fixes a few. [GH-4159]

View File

@ -435,10 +435,6 @@ module Vagrant
# means we were interrupted as well.
@download_interrupted = true
env[:ui].info(I18n.t("vagrant.actions.box.download.interrupted"))
rescue Errors::DownloaderError
# The download failed for some reason, clean out the temp path
File.unlink(d.destination) if File.file?(d.destination)
raise
end
Pathname.new(d.destination)