aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorAdam Vandenberg2010-04-04 13:45:02 -0700
committerAdam Vandenberg2010-04-04 13:46:41 -0700
commitfb9f4bbccc640fb4b86557885e5cfdc0cb2ce743 (patch)
treee41c5327de899f0b85ccabd29f11c19e631e7ef0 /Library
parentd2b2ecbd0b719e0839b51e3a83bedb5686faf84b (diff)
downloadbrew-fb9f4bbccc640fb4b86557885e5cfdc0cb2ce743.tar.bz2
Don't link_dir if the target doesn't exist.
Fixes Homebrew/homebrew#1115 for Ruby 1.9, thanks to assaf.
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/keg.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/Library/Homebrew/keg.rb b/Library/Homebrew/keg.rb
index 957d9806d..3413775a9 100644
--- a/Library/Homebrew/keg.rb
+++ b/Library/Homebrew/keg.rb
@@ -80,6 +80,7 @@ protected
# symlinks the contents of self+foo recursively into /usr/local/foo
def link_dir foo
root = self+foo
+ return unless root.exist?
root.find do |src|
next if src == root