same as 6e94b1809f67: ENOTDIR is ENOENT on windows

This commit is contained in:
Benjamin Peterson 2011-08-18 14:49:17 -05:00
parent 5bd34f8ecc
commit 6ca3c980bf
1 changed files with 2 additions and 1 deletions

View File

@ -106,7 +106,8 @@ class AssertionRewritingHook(object):
# common case) or it's blocked by a non-dir node. In the # common case) or it's blocked by a non-dir node. In the
# latter case, we'll ignore it in _write_pyc. # latter case, we'll ignore it in _write_pyc.
pass pass
elif e == errno.ENOTDIR: elif (e == errno.ENOTDIR or
sys.platform == "win32" and e == errno.ENOENT):
# One of the path components was not a directory, likely # One of the path components was not a directory, likely
# because we're in a zip file. # because we're in a zip file.
write = False write = False