diff options
Diffstat (limited to 'release')
-rw-r--r-- | release/scripts/modules/bpy/path.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/release/scripts/modules/bpy/path.py b/release/scripts/modules/bpy/path.py index ccc9df93b0d..874efc2e131 100644 --- a/release/scripts/modules/bpy/path.py +++ b/release/scripts/modules/bpy/path.py @@ -219,7 +219,10 @@ def resolve_ncase(path): # we are expecting 'dirpath' to be a directory, but it could be a file if _os.path.isdir(dirpath): - files = _os.listdir(dirpath) + try: + files = _os.listdir(dirpath) + except PermissionError: # We might not have the permission to list dirpath... + return path, False else: return path, False |