diff options
author | Zac Medico <zmedico@gentoo.org> | 2007-01-27 22:58:49 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2007-01-27 22:58:49 +0000 |
commit | 4c783e524aeab68f5a1f19d9559021831c40e3f4 (patch) | |
tree | c5f14e33e7fae806b5ac0395d67be417d5ae299a | |
parent | 506cc0b2d692e28812af48682d301479a3949bed (diff) | |
download | portage-4c783e524aeab68f5a1f19d9559021831c40e3f4.tar.gz portage-4c783e524aeab68f5a1f19d9559021831c40e3f4.tar.bz2 portage-4c783e524aeab68f5a1f19d9559021831c40e3f4.zip |
Ignore EEXIST from rmdir since some kernels (such as solaris) return that instead of ENOTEMPTY.
svn path=/main/trunk/; revision=5798
-rwxr-xr-x | bin/emerge | 3 | ||||
-rw-r--r-- | pym/portage/__init__.py | 9 |
2 files changed, 8 insertions, 4 deletions
diff --git a/bin/emerge b/bin/emerge index e4100b73b..119705691 100755 --- a/bin/emerge +++ b/bin/emerge @@ -2993,7 +2993,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/__init__.py b/pym/portage/__init__.py index ee911fc7e..f58af8411 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -6349,7 +6349,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 @@ -6961,7 +6962,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) @@ -7966,7 +7968,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) |