Bug #205318 - Handle errno.ENOTDIR thrown from the lstat call
authorZac Medico <zmedico@gentoo.org>
Fri, 11 Jan 2008 23:07:10 +0000 (23:07 -0000)
committerZac Medico <zmedico@gentoo.org>
Fri, 11 Jan 2008 23:07:10 +0000 (23:07 -0000)
inside dblink._security_check().

svn path=/main/trunk/; revision=9188

pym/portage/dbapi/vartree.py

index efaee6edecca6da3217c9702899ccb66dceb8e6c..98f751f50e83c48529dfc9c03a5c97f4e508b7aa 100644 (file)
@@ -1701,7 +1701,7 @@ class dblink(object):
                        try:
                                s = os.lstat(path)
                        except OSError, e:
-                               if e.errno != errno.ENOENT:
+                               if e.errno not in (errno.ENOENT, errno.ENOTDIR):
                                        raise
                                del e
                                continue