Skip to content
Snippets Groups Projects
Commit e2e35def authored by Martin Afanasjew's avatar Martin Afanasjew
Browse files

bottle: avoid raising exception in ensure block

The `ensure` block can be reached before the tab is modified (and thus
before `original_tab` gets populated). Avoid raising an exception when
attempting to restore a tab that hasn't been modified yet, e.g. because
relocating some of the Mach-O binaries failed.
parent 66cda616
No related branches found
No related tags found
No related merge requests found
......@@ -255,7 +255,7 @@ module Homebrew
raise
ensure
ignore_interrupts do
original_tab.write
original_tab.write if original_tab
keg.relocate_install_names Keg::PREFIX_PLACEHOLDER, prefix,
Keg::CELLAR_PLACEHOLDER, cellar
keg.relocate_text_files Keg::PREFIX_PLACEHOLDER, prefix,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment