diff options
author | Zac Medico <zmedico@gentoo.org> | 2008-11-15 04:28:56 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2008-11-15 04:28:56 +0000 |
commit | 22e9978f6b07d0b4183b3b330c13f2a8ec8db11b (patch) | |
tree | e280cbe5e4dc1c078aa4046eb1e2a7630e8eeb77 | |
parent | 1b155f7bcf030e093d74505df070db8424cabd2e (diff) | |
download | portage-22e9978f6b07d0b4183b3b330c13f2a8ec8db11b.tar.gz portage-22e9978f6b07d0b4183b3b330c13f2a8ec8db11b.tar.bz2 portage-22e9978f6b07d0b4183b3b330c13f2a8ec8db11b.zip |
Bug #243022 - Inside dblink.mergeme(), when merging a directory and a symlink
is in the way, verify that if points to a directory before accepting it,
otherwise move it out of the way. (trunk r11920)
svn path=/main/branches/2.1.6/; revision=11921
-rw-r--r-- | pym/portage/dbapi/vartree.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py index 31ad8880c..2555657ba 100644 --- a/pym/portage/dbapi/vartree.py +++ b/pym/portage/dbapi/vartree.py @@ -2641,7 +2641,8 @@ class dblink(object): writemsg("!!! And finish by running this: env-update\n\n") return 1 - if stat.S_ISLNK(mydmode) or stat.S_ISDIR(mydmode): + if stat.S_ISDIR(mydmode) or \ + (stat.S_ISLNK(mydmode) and os.path.isdir(mydest)): # a symlink to an existing directory will work for us; keep it: showMessage("--- %s/\n" % mydest) if bsd_chflags: |