summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2006-07-12 09:59:01 +0000
committerZac Medico <zmedico@gentoo.org>2006-07-12 09:59:01 +0000
commite3cd333f04906fd72bf82c48d3ef47e206aa8d8e (patch)
tree05461c0e6cf25555740fb795ccf4eaf911729b0b
parent4012df08b74a8a3a5e680cd675783c05900b3de6 (diff)
downloadportage-e3cd333f04906fd72bf82c48d3ef47e206aa8d8e.tar.gz
portage-e3cd333f04906fd72bf82c48d3ef47e206aa8d8e.tar.bz2
portage-e3cd333f04906fd72bf82c48d3ef47e206aa8d8e.zip
Use a safer method to join the path when deciding if the current merge offset is config protected. The main problem with corresponding change from r3836 is that the destroot variable happens to be // when ROOT=/. See bug #140045.
svn path=/main/trunk/; revision=3837
-rw-r--r--pym/portage.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/pym/portage.py b/pym/portage.py
index dccdc706b..7a614dbd6 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -6442,7 +6442,10 @@ class dblink:
# We need mydest defined up here to calc. protection paths. This is now done once per
# directory rather than once per file merge. This should really help merge performance.
# Trailing / ensures that protects/masks with trailing /'s match.
- mytruncpath = os.path.join(destroot, offset) + os.path.sep
+ mytruncpath = os.path.sep + \
+ os.path.join(
+ destroot.strip(os.path.sep), offset.strip(os.path.sep)) + \
+ os.path.sep
myppath=self.isprotected(mytruncpath)
else:
mergelist=stufftomerge