summaryrefslogtreecommitdiffstats
path: root/pym/_emerge/unmerge.py
diff options
context:
space:
mode:
authorMounir Lamouri <volkmar@gentoo.org>2009-08-15 19:24:12 +0000
committerMounir Lamouri <volkmar@gentoo.org>2009-08-15 19:24:12 +0000
commit3273deb3408f0b460954e97f0a815a2485d0c2d8 (patch)
treed0f9bb9d878774703605acd30a50a0ddd6c97bb1 /pym/_emerge/unmerge.py
parent68a3a0a29a7d422a09aeb5c2b14010904bb683b7 (diff)
downloadportage-3273deb3408f0b460954e97f0a815a2485d0c2d8.tar.gz
portage-3273deb3408f0b460954e97f0a815a2485d0c2d8.tar.bz2
portage-3273deb3408f0b460954e97f0a815a2485d0c2d8.zip
sets/files.py cleanPackages function stop calling lock and load
and requires the caller to do that changing unmerge to reflect this change svn path=/main/trunk/; revision=14069
Diffstat (limited to 'pym/_emerge/unmerge.py')
-rw-r--r--pym/_emerge/unmerge.py15
1 files changed, 13 insertions, 2 deletions
diff --git a/pym/_emerge/unmerge.py b/pym/_emerge/unmerge.py
index 25c3e4e4f..2c9e7576e 100644
--- a/pym/_emerge/unmerge.py
+++ b/pym/_emerge/unmerge.py
@@ -510,11 +510,22 @@ def unmerge(root_config, myopts, unmerge_action,
raise UninstallFailure(retval)
sys.exit(retval)
else:
- if clean_world and hasattr(sets["world"], "cleanPackage"):
+ if clean_world and hasattr(sets["world"], "cleanPackage")\
+ and hasattr(sets["world"], "lock"):
+ sets["world"].lock()
+ if hasattr(sets["world"], "load"):
+ sets["world"].load()
sets["world"].cleanPackage(vartree.dbapi, y)
+ sets["world"].unlock()
emergelog(xterm_titles, " >>> unmerge success: "+y)
- if clean_world and hasattr(sets["world"], "remove"):
+
+ if clean_world and hasattr(sets["world"], "remove")\
+ and hasattr(sets["world"], "lock"):
+ sets["world"].lock()
+ # load is called inside remove()
for s in root_config.setconfig.active:
sets["world"].remove(SETPREFIX+s)
+ sets["world"].unlock()
+
return 1