Permalink
Browse files

oe.path: also rmtree on EPERM

Ran into this under OSX for some reason.

Signed-off-by: Chris Larson <chris_larson@mentor.com>
  • Loading branch information...
1 parent a441183 commit bbe3dc4506c604a24010b4aeb8c3deee760fd7ae @kergoth kergoth committed Nov 3, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/oe/path.py
View
@@ -49,7 +49,7 @@ def remove(path, recurse=True):
try:
os.unlink(path)
except OSError, exc:
- if recurse and exc.errno == errno.EISDIR:
+ if recurse and exc.errno in (errno.EISDIR, errno.EPERM):
shutil.rmtree(path)
elif exc.errno != errno.ENOENT:
raise

0 comments on commit bbe3dc4

Please sign in to comment.