Fix handling of broken symlinks in rb-site

Review Request #665 — Created Dec. 9, 2008 and submitted

Information

Review Board SVN (deprecated)

Reviewers

Running "rb-site upgrade <path>" will fail if one of the media symlinks in <path> is broken. os.path.exists will say that the symlink doesn't exist, and then an exception will get thrown a few lines later when trying to create a symlink that already exists. This checks to see if dest_dir is broken symlink before doing anything, and if so, removes it.
Ran rb-site upgrade with valid and invalid symlinks.
chipx86
  1. Looks good. Thanks Brett!
    
    Committed as r1633.
  2. 
      
Loading...