projects
/
portage.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
edff962
)
Don't use os.path.isdir() because it can swallow errors related to filesystem/disk...
v2.1.2-r6
author
Zac Medico
<zmedico@gentoo.org>
Thu, 1 Feb 2007 20:22:16 +0000
(20:22 -0000)
committer
Zac Medico
<zmedico@gentoo.org>
Thu, 1 Feb 2007 20:22:16 +0000
(20:22 -0000)
svn path=/main/branches/2.1.2/; revision=5869
pym/portage.py
patch
|
blob
|
history
diff --git
a/pym/portage.py
b/pym/portage.py
index b7ba73f37274b6135099c671ff24adb36e8af353..25c4d7a14484f3e41c44dbe80376f1241adaf4fd 100644
(file)
--- a/
pym/portage.py
+++ b/
pym/portage.py
@@
-5271,8
+5271,14
@@
class vardbapi(dbapi):
def _aux_get(self, mycpv, wants):
mydir = os.path.join(self.root, VDB_PATH, mycpv)
- if not os.path.isdir(mydir):
- raise KeyError(mycpv)
+ try:
+ if not stat.S_ISDIR(os.stat(mydir).st_mode):
+ raise KeyError(mycpv)
+ except OSError, e:
+ if e.errno == errno.ENOENT:
+ raise KeyError(mycpv)
+ del e
+ raise
results = []
for x in wants:
try: