]> granicus.if.org Git - python/commitdiff
Don't chmod() if path is a symlink.
authorBarry Warsaw <barry@python.org>
Wed, 4 Jun 2014 18:11:46 +0000 (14:11 -0400)
committerBarry Warsaw <barry@python.org>
Wed, 4 Jun 2014 18:11:46 +0000 (14:11 -0400)
Lib/venv/__init__.py

index c258b1c05a495b03eb14eac3af00400b653b97c8..b5ef2d88e99ffe9e0aef1dca2df3ec5c3de8d089 100644 (file)
@@ -215,7 +215,8 @@ class EnvBuilder:
                     # Issue 18807: make copies if
                     # symlinks are not wanted
                     copier(context.env_exe, path)
-                    os.chmod(path, 0o755)
+                    if not os.path.islink(path):
+                        os.chmod(path, 0o755)
         else:
             subdir = 'DLLs'
             include = self.include_binary