aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/cmd/reinstall.rb7
1 files changed, 3 insertions, 4 deletions
diff --git a/Library/Homebrew/cmd/reinstall.rb b/Library/Homebrew/cmd/reinstall.rb
index 0331d7735..53f7f1930 100644
--- a/Library/Homebrew/cmd/reinstall.rb
+++ b/Library/Homebrew/cmd/reinstall.rb
@@ -28,10 +28,9 @@ module Homebrew extend self
backup keg
end
self.install_formula formula
- rescue Exception => e
- ofail e.message unless e.message.empty?
- restore_backup keg, formula
- raise 'Reinstall failed.'
+ rescue Exception
+ ignore_interrupts { restore_backup(keg, formula) }
+ raise
else
backup_path(keg).rmtree if backup_path(keg).exist?
end