summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-01-29 01:46:37 +0000
committerZac Medico <zmedico@gentoo.org>2007-01-29 01:46:37 +0000
commit0dc60ce69567f79f5d05148d80109cd7a6e93785 (patch)
treec0e0198682fd37feb7e06c8eb47090d3f9a12459
parentCatch EACCESS when running env-update, orignal patch by <phajdan.jr@gmail.com... (diff)
downloadportage-multirepo-0dc60ce69567f79f5d05148d80109cd7a6e93785.tar.gz
portage-multirepo-0dc60ce69567f79f5d05148d80109cd7a6e93785.tar.bz2
portage-multirepo-0dc60ce69567f79f5d05148d80109cd7a6e93785.zip
Ignore EEXIST from rmdir since some kernels (such as solaris) return that instead of ENOTEMPTY. (trunk r5798)v2.1.2-r5
svn path=/main/branches/2.1.2/; revision=5830
-rwxr-xr-xbin/emerge3
-rw-r--r--pym/portage.py9
2 files changed, 8 insertions, 4 deletions
diff --git a/bin/emerge b/bin/emerge
index 1302818a..a3561aee 100755
--- a/bin/emerge
+++ b/bin/emerge
@@ -2992,7 +2992,8 @@ class MergeTask(object):
try:
os.rmdir(catdir)
except OSError, e:
- if e.errno != errno.ENOTEMPTY:
+ if e.errno not in (errno.ENOENT,
+ errno.ENOTEMPTY, errno.EEXIST):
raise
del e
portage_locks.unlockdir(catdir_lock)
diff --git a/pym/portage.py b/pym/portage.py
index 8b97cc5b..b7ba73f3 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -6284,7 +6284,8 @@ class binarytree(object):
try:
os.rmdir(os.path.join(self.pkgdir, mycat))
except OSError, e:
- if e.errno not in (errno.ENOENT, errno.ENOTEMPTY):
+ if e.errno not in (errno.ENOENT,
+ errno.ENOTEMPTY, errno.EEXIST):
raise
del e
@@ -6896,7 +6897,8 @@ class dblink:
try:
os.rmdir(catdir)
except OSError, e:
- if e.errno != errno.ENOTEMPTY:
+ if e.errno not in (errno.ENOENT,
+ errno.ENOTEMPTY, errno.EEXIST):
raise
del e
portage_locks.unlockdir(catdir_lock)
@@ -7901,7 +7903,8 @@ def pkgmerge(mytbz2, myroot, mysettings, mydbapi=None, vartree=None, prev_mtimes
try:
os.rmdir(catdir)
except OSError, e:
- if e.errno != errno.ENOTEMPTY:
+ if e.errno not in (errno.ENOENT,
+ errno.ENOTEMPTY, errno.EEXIST):
raise
del e
portage_locks.unlockdir(catdir_lock)